---
title: "CGGetDisplayTransferByTable(_:_:_:_:_:_:)"
framework: coregraphics
role: symbol
role_heading: Function
path: "coregraphics/cggetdisplaytransferbytable(_:_:_:_:_:_:)"
---

# CGGetDisplayTransferByTable(_:_:_:_:_:_:)

Gets the values in the RGB gamma tables for a display.

## Declaration

```swift
func CGGetDisplayTransferByTable(_ display: CGDirectDisplayID, _ capacity: UInt32, _ redTable: UnsafeMutablePointer<CGGammaValue>?, _ greenTable: UnsafeMutablePointer<CGGammaValue>?, _ blueTable: UnsafeMutablePointer<CGGammaValue>?, _ sampleCount: UnsafeMutablePointer<UInt32>?) -> CGError
```

## Parameters

- `display`: The identifier of the display to be accessed.
- `capacity`: The number of entries each table can hold.
- `redTable`: A pointer to an array of type CGGammaValue with size capacity. On return, the array contains the values of the red channel in the display’s gamma table.
- `greenTable`: A pointer to an array of type CGGammaValue with size capacity. On return, the array contains the values of the green channel in the display’s gamma table.
- `blueTable`: A pointer to an array of type CGGammaValue with size capacity. On return, the array contains the values of the blue channel in the display’s gamma table.
- `sampleCount`: The number of samples actually copied into each array.

## Return Value

Return Value A result code. See Core Graphics Data Types and Constants.

## See Also

### Functions

- [CGAcquireDisplayFadeReservation(_:_:)](coregraphics/cgacquiredisplayfadereservation(_:_:).md)
- [CGAssociateMouseAndMouseCursorPosition(_:)](coregraphics/cgassociatemouseandmousecursorposition(_:).md)
- [CGBeginDisplayConfiguration(_:)](coregraphics/cgbegindisplayconfiguration(_:).md)
- [CGCancelDisplayConfiguration(_:)](coregraphics/cgcanceldisplayconfiguration(_:).md)
- [CGCaptureAllDisplays()](coregraphics/cgcapturealldisplays().md)
- [CGCaptureAllDisplaysWithOptions(_:)](coregraphics/cgcapturealldisplayswithoptions(_:).md)
- [CGCompleteDisplayConfiguration(_:_:)](coregraphics/cgcompletedisplayconfiguration(_:_:).md)
- [CGConfigureDisplayFadeEffect(_:_:_:_:_:_:)](coregraphics/cgconfiguredisplayfadeeffect(_:_:_:_:_:_:).md)
- [CGConfigureDisplayMirrorOfDisplay(_:_:_:)](coregraphics/cgconfiguredisplaymirrorofdisplay(_:_:_:).md)
- [CGConfigureDisplayMode(_:_:_:)](coregraphics/cgconfiguredisplaymode(_:_:_:).md)
- [CGConfigureDisplayOrigin(_:_:_:_:)](coregraphics/cgconfiguredisplayorigin(_:_:_:_:).md)
- [CGConfigureDisplayStereoOperation(_:_:_:_:)](coregraphics/cgconfiguredisplaystereooperation(_:_:_:_:).md)
- [CGConfigureDisplayWithDisplayMode(_:_:_:_:)](coregraphics/cgconfiguredisplaywithdisplaymode(_:_:_:_:).md)
- [CGCursorIsDrawnInFramebuffer()](coregraphics/cgcursorisdrawninframebuffer().md)
- [CGCursorIsVisible()](coregraphics/cgcursorisvisible().md)
