Instance Method

initWithFrame:pixelFormat:

Returns an NSOpenGLView object initialized with the specified frame rectangle and pixel format.

Declaration

- (instancetype)initWithFrame:(NSRect)frameRect pixelFormat:(NSOpenGLPixelFormat *)format;

Parameters

frameRect

The frame rectangle for the view, specified in the coordinate system of its parent view.

format

The pixel format to use when creating the view's NSOpenGLContext object.

Return Value

An initialized NSOpenGLView object, or nil if the object could not be initialized.

See Also