AGL

Create and manage OpenGL rendering contexts for use in macOS, and perform operations on drawable objects.

Overview

To use AGL from the Carbon framework, your application must link to both the AGL and the OpenGL (OpenGL/OpenGL.h) frameworks.

Topics

Managing Pixel Format Objects

aglCreatePixelFormat

Creates a pixel format with the provided attributes.

Deprecated
aglChoosePixelFormat

Creates a pixel format object that satisfies the constraints of the specified buffer and renderer attributes.

Deprecated
aglDescribePixelFormat

Retrieves the value of an attribute associated with a pixel format object.

Deprecated
aglDestroyPixelFormat

Frees the memory associated with a pixel format object.

Deprecated
aglGetCGLPixelFormat

Gets the CGL pixel format object associated with an AGL pixel format.

Deprecated
aglDisplaysOfPixelFormat

Returns the graphics devices supported by a pixel format object.

Deprecated
aglDevicesOfPixelFormat

Returns the graphics devices supported by a pixel format object.

Deprecated
aglNextPixelFormat

Returns the next pixel format object in a list of pixel format objects.

Deprecated

Managing Contexts

aglCreateContext

Creates an AGL rendering context.

Deprecated
aglCopyContext

Copies the specified state variables from one rendering context to another.

Deprecated
aglDestroyContext

Frees the resources associated with a rendering context.

Deprecated
aglGetCGLContext

Gets the CGL rendering context associated with an AGL rendering context.

Deprecated
aglGetCurrentContext

Returns the current rendering context.

Deprecated
aglSetCurrentContext

Sets the specified rendering context as the current rendering context.

Deprecated
aglSwapBuffers

Exchanges the front and back buffers of the specified rendering context.

Deprecated
aglUpdateContext

Notifies the rendering context that the window geometry has changed.

Deprecated

Getting and Setting Context Options

aglEnable

Enables an option for a rendering context.

Deprecated
aglDisable

Disables an option for a rendering context.

Deprecated
aglIsEnabled

Reports whether an option is enabled for a rendering context.

Deprecated
aglSetInteger

Sets the value of an option for a rendering context.

Deprecated
aglGetInteger

Retrieves the integer setting of an AGL context option.

Deprecated

Managing Drawable Objects

aglGetDrawable

Returns the drawable object attached to a rendering context.

Deprecated
aglSetDrawable

Attaches a rendering context to a Carbon window.

Deprecated
aglSetFullScreen

Attaches a rendering context to a full screen graphics device.

Deprecated
aglSetOffScreen

Attaches a rendering context to an offscreen memory area.

Deprecated

Managing Pixel Buffers

aglCreatePBuffer

Creates a pixel buffer of the specified size, compatible with the specified texture target.

Deprecated
aglDestroyPBuffer

Releases the resources associated with a pixel buffer object.

Deprecated
aglDescribePBuffer

Retrieves information that describes the specified pixel buffer object.

Deprecated
aglGetPBuffer

Retrieves a pixel buffer and its parameters for a specified rendering context.

Deprecated
aglSetPBuffer

Attaches a pixel buffer object to a rendering context.

Deprecated
aglTexImagePBuffer

Binds the contents of a pixel buffer to a data source for a texture object.

Deprecated

Using a Window as a Texture Source

aglSurfaceTexture

Allows texturing from a drawable object that has an attached rendering context, using the surface contents as the source data for the texture.

Deprecated

Getting Error Information

aglGetError

Returns an AGL error code.

Deprecated
aglErrorString

Returns a string that describes the specified AGL error code.

Deprecated

Getting and Setting Global Information

aglConfigure

Sets the value of a global option.

Deprecated
aglGetVersion

Gets the major and minor version numbers of the AGL library.

Deprecated
aglResetLibrary

Resets the AGL library.

Deprecated

Getting Renderer Information

aglDescribeRenderer

Obtains the value associated with a renderer property.

Deprecated
aglDestroyRendererInfo

Frees resources associated with a renderer information object.

Deprecated
aglNextRendererInfo

Returns the next renderer information object.

Deprecated
aglQueryRendererInfo

Creates and returns a renderer information object that contains properties and values for all renderers driving the specified displays.

Deprecated
aglQueryRendererInfoForCGDirectDisplayIDs

Creates and returns a renderer information object that contains properties and values for all renderers driving the specified displays.

Deprecated

Generating Bitmap Display Lists

aglUseFont

Creates bitmap display lists from a font.

Deprecated

Managing Virtual Screens

aglGetVirtualScreen

Returns the current virtual screen number associated with a rendering context.

Deprecated
aglSetVirtualScreen

Forces subsequent OpenGL commands to the specified virtual screen.

Deprecated

Getting and Setting Windows

aglSetWindowRef

Sets an AGL context to the specified window.

Deprecated
aglGetWindowRef

Retrieves the window associated with an AGL context.

Deprecated

Getting and Setting HIView Objects

aglSetHIViewRef

Sets an AGL context to the specified HIView object.

Deprecated
aglGetHIViewRef

Retrieves the HIView object associated with an AGL context.

Deprecated

Data Types

AGLContext

Represents a pointer to an opaque AGL context object.

Deprecated
AGLDevice

Defines a reference to a list of graphics devices.

Deprecated
AGLDrawable

Defines an opaque data type that represents a Carbon window.

Deprecated
AGLPbuffer

Represents a pointer to an opaque pixel buffer object.

Deprecated
AGLPixelFormat

Represents a pointer to an opaque pixel format object.

Deprecated
AGLRendererInfo

Represents a pointer to an opaque renderer information object.

Deprecated

Constants

Bit Depths

Define resolutions for the depth and stencil buffers.

Buffer and Renderer Attributes

Specify attributes used to create a pixel format object.

Buffer Mode Flags

Define constants used to set buffer modes.

Color Modes

Specify formats and color channel layout information for the color buffer.

Context Options and Parameters

Define options and parameters that apply to a specific rendering context.

Error Codes

Defines the error codes that can be returned by the aglGetError function.

Globally Configured Options

Specify options that apply globally.

Renderer Attributes

Define options for managing renderers.

Renderer IDs

Define constants that specify hardware and software renderers.

Renderer Properties

Specify constants that you can use to query renderer properties.

See Also