Class

NSOpenGLPixelFormat

An object that specifies the types of buffers and other attributes of the NSOpenGLContext.

Declaration

@interface NSOpenGLPixelFormat : NSObject

Overview

To render with OpenGL into an NSOpenGLContext, you must specify the context’s pixel format. The NSOpenGLPixelFormat class is similar to the AGLPixelFormat type.

Every NSOpenGLPixelFormat object wraps a low-level, platform-specific Core OpenGL (CGL) pixel format object. Your application can retrieve the CGL pixel format object by calling the CGLPixelFormatObj method. For more information on the underling CGL pixel format object, see CGL.

Topics

Creating an NSOpenGLPixelFormat Object

- initWithCGLPixelFormatObj:

Returns an NSOpenGLPixelFormatobject initialized with using an existing CGL pixel format object.

- initWithData:

Returns an NSOpenGLPixelFormat object initialized with specified pixel format attribute data.

- initWithAttributes:

Returns an NSOpenGLPixelFormat object initialized with specified pixel format attributes.

Managing the Pixel Format

CGLPixelFormatObj

Returns the low-level, platform-specific Core OpenGL (CGL) pixel format object represented by the receiver.

- getValues:forAttribute:forVirtualScreen:

Gets the value for the specified pixel format attribute.

numberOfVirtualScreens

Returns the number of virtual screens associated with the receiver.

Managing Attributes

- attributes

Retrieves the attribute data for the pixel format object.

- setAttributes:

Sets the attribute data for the pixel format object.

Constants

OpenGL Pixel Format Attributes

Pixel format attributes for OpenGL.

OpenGL Profiles

Defines constants that specify the functionality provided by the renderer.

Relationships

Inherits From

Conforms To

See Also

OpenGL

NSOpenGLContext

An object that represents an OpenGL graphics context, into which all OpenGL calls are rendered.

Deprecated
NSOpenGLLayer

A subclass of CAOpenGLLayer that is suitable for rendering OpenGL into layers.

Deprecated
NSOpenGLPixelBuffer

An object that provides access to accelerated offscreen rendering.

Deprecated
NSOpenGLGlobalOption

These constants are option names for NSOpenGLSetOption and NSOpenGLGetOption.

Deprecated
NSOpenGLGetOption

Returns global OpenGL options.

Deprecated
NSOpenGLGetVersion

Returns the NSOpenGL version numbers.

Deprecated
NSOpenGLSetOption

Sets global OpenGL options.

Deprecated