CVDisplayLink

A high-priority thread that notifies your app when a given display will need each frame.

Overview

A Core Video display link provides a separate high-priority thread to notify your application when a given display will need each frame. You can use a display link to easily synchronize with the refresh rate of a display. The display link API uses the Core Foundation class system internally to provide reference counting behavior and other useful properties.

Topics

Creating Display Links

CVDisplayLinkCreateWithCGDisplay

Creates a display link for a single display.

CVDisplayLinkCreateWithCGDisplays

Creates a display link for an array of displays.

CVDisplayLinkCreateWithActiveCGDisplays

Creates a display link capable of being used with all active displays.

CVDisplayLinkCreateWithOpenGLDisplayMask

Creates a display link from an OpenGL display mask.

Configuring Display Links

CVDisplayLinkSetCurrentCGDisplay

Sets the current display of a display link.

CVDisplayLinkSetCurrentCGDisplayFromOpenGLContext

Selects the display link most optimal for the current renderer of an OpenGL context.

CVDisplayLinkSetOutputCallback

Sets the renderer output callback function.

Inspecting Display Links

CVDisplayLinkGetCurrentCGDisplay

Gets the current display associated with a display link.

CVDisplayLinkGetCurrentTime

Retrieves the current (“now”) time of a given display link.

CVDisplayLinkTranslateTime

Translates the time in the display link’s time base from one representation to another.

CVDisplayLinkGetActualOutputVideoRefreshPeriod

Retrieves the actual output refresh period of a display as measured by the system time.

CVDisplayLinkGetNominalOutputVideoRefreshPeriod

Retrieves the nominal refresh period of a display link.

CVDisplayLinkGetOutputVideoLatency

Retrieves the nominal latency of a display link.

CVDisplayLinkIsRunning

Indicates whether a given display link is running.

CVDisplayLinkGetTypeID

Obtains the Core Foundation ID for the display link data type.

Retaining and Releasing Display Links

CVDisplayLinkRelease

Releases a display link.

CVDisplayLinkRetain

Retains a display link.

Managing Display Links

CVDisplayLinkStart

Activates a display link.

CVDisplayLinkStop

Stops a display link.

Data Types

CVDisplayLinkRef

A reference to a display link object.

CVOptionFlags

The flags to be used for the display link output callback function.

Callbacks

CVDisplayLinkOutputCallback

Defines a pointer to a display link output callback function, which is called whenever the display link wants the application to output a frame.

See Also

Time Management

CVTime

A structure used for storing Core Video time values.