Mac Developer Library

Developer

CVOpenGLBufferPool Reference

Options
Deployment Target:

On This Page
Language:

CVOpenGLBufferPool Reference

An OpenGL buffer pool is a utility object for managing a set of OpenGL buffer objects for repeated use. OpenGL buffer pools allocate a number of buffers in video memory that can be reused as needed, avoiding repeated allocations and deallocations, which hurt performance.

Functions

Data Types

  • A reference to an OpenGL buffer pool object.

    Declaration

    Swift

    class CVOpenGLBufferPool { }

    Objective-C

    typedef struct _CVOpenGLBufferPool *CVOpenGLBufferPoolRef;

    Import Statement

    Objective-C

    @import CoreVideo;

    Swift

    import CoreVideo

    Availability

    Available in OS X v10.3 and later.

Constants

  • The attributes associated with an OpenGL buffer pool.

    Declaration

    Swift

    let kCVOpenGLBufferPoolMinimumBufferCountKey: CFString let kCVOpenGLBufferPoolMaximumBufferAgeKey: CFString

    Objective-C

    const CFStringRef kCVOpenGLBufferPoolMinimumBufferCountKey; const CFStringRef kCVOpenGLBufferPoolMaximumBufferAgeKey;

    Constants

    • kCVOpenGLBufferPoolMinimumBufferCountKey

      kCVOpenGLBufferPoolMinimumBufferCountKey

      The minimum number of buffers to be kept in the pool (type CFNumber).

      Available in OS X v10.4 and later.

    • kCVOpenGLBufferPoolMaximumBufferAgeKey

      kCVOpenGLBufferPoolMaximumBufferAgeKey

      The maximum time that unused buffers should be kept before they are deallocated (type CFAbsoluteTime).

      Available in OS X v10.4 and later.

    Discussion

    You specify these keys in a Core Foundation dictionary when calling functions such as CVOpenGLBufferPoolCreate.