Vuo  0.5.3
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Typedefs | Functions | Variables
VuoGlPool.cc File Reference

Description

VuoGlPool implementation.

Typedefs

typedef map< GLuint, unsigned int > VuoGlTexturePool
 The number of times each glTextureName is retained.
 

Functions

GLuint VuoGlPool_use (VuoGlPoolType type)
 Returns an OpenGL object of type type.
 
void VuoGlPool_disuse (VuoGlPoolType type, GLuint name)
 Indicates that the caller is done using the OpenGL object name of type type.
 
void VuoGlTexture_retain (GLuint glTextureName)
 Increments the reference count for glTextureName.
 
void VuoGlTexture_release (GLuint glTextureName)
 Decrements the reference count for glTextureName.
 

Variables

VuoGlTexturePool VuoGlTexturePool_referenceCounts
 The reference count for each OpenGL Texture Object.
 
dispatch_semaphore_t VuoGlTexturePool_referenceCountsSemaphore = NULL
 Synchronizes access to VuoGlTexturePool_referenceCounts.
 

Typedef Documentation

typedef map<GLuint, unsigned int> VuoGlTexturePool

The number of times each glTextureName is retained.

Function Documentation

void VuoGlPool_disuse ( VuoGlPoolType  type,
GLuint  name 
)

Indicates that the caller is done using the OpenGL object name of type type.

The object is returned to the pool, so other callers can use it (which is more efficient than deleting and re-generating objects).

This function may be called from any thread.

Todo:
https://b33p.net/kosada/node/6752
Todo:
https://b33p.net/kosada/node/5937
GLuint VuoGlPool_use ( VuoGlPoolType  type)

Returns an OpenGL object of type type.

If an existing, unused object is available, it is returned. Otherwise, a new object is created.

This function may be called from any thread.

void VuoGlTexture_release ( GLuint  glTextureName)

Decrements the reference count for glTextureName.

This function may be called from any thread.

void VuoGlTexture_retain ( GLuint  glTextureName)

Increments the reference count for glTextureName.

This function may be called from any thread.

Variable Documentation

VuoGlTexturePool VuoGlTexturePool_referenceCounts

The reference count for each OpenGL Texture Object.

dispatch_semaphore_t VuoGlTexturePool_referenceCountsSemaphore = NULL

Synchronizes access to VuoGlTexturePool_referenceCounts.