VuoShader C type definition.
- Copyright
- Copyright © 2012–2013 Kosada Incorporated. This code may be modified and distributed under the terms of the MIT License. For more information, see http://vuo.org/license.
|
VuoShader | VuoShader_make (const char *summary, const char *vertexShaderSource, const char *fragmentShaderSource) |
| Compiles, links, and uploads the specified shader sources.
|
|
VuoShader | VuoShader_valueFromString (const char *initializer) |
| Parses the C string initializer to create a new value.
|
|
char * | VuoShader_stringFromValue (const VuoShader value) |
| Serializes value as a C string.
|
|
char * | VuoShader_summaryFromValue (const VuoShader value) |
| Returns a summary of the shader: the text description provided to VuoShader_make() , and the number of textures associated with the shader.
|
|
VuoShader | VuoShader_valueFromJson (json_object *js) |
| Decodes the JSON object js , expected to contain a 64-bit integer (memory address or 0), to create a new VuoShader .
|
|
json_object * | VuoShader_jsonFromValue (const VuoShader value) |
| Encodes value as a JSON object.
|
|
void | VuoShader_setUniformFloat (VuoShader shader, const char *uniformIdentifier, float value) |
| Sets a float uniform value on the specified shader .
|
|
void | VuoShader_setUniformPoint2d (VuoShader shader, const char *uniformIdentifier, VuoPoint2d value) |
| Sets a float uniform value on the specified shader .
|
|
const char * | VuoShader_getDefaultVertexShader (void) |
| Returns the default vertex shader, which projects verties and passes through texture coordinates.
|
|
VuoShader | VuoShader_makeImageShader (void) |
| Returns a shader that renders objects with an image (ignoring lighting), specified by uniform texture .
|
|
void | VuoShader_resetTextures (VuoShader shader) |
| Empties the list of textures associated with shader .
|
|
void | VuoShader_addTexture (VuoShader shader, VuoImage texture, const char *uniformIdentifier) |
| Adds to shader an association between texture and uniformIdentifier .
|
|
void | VuoShader_activateTextures (VuoShader shader) |
| Assigns each of the shader's textures to a texture unit, and passes the texture unit number along to the shader.
|
|
void | VuoShader_deactivateTextures (VuoShader shader) |
| Unbinds the texture units used by this shader.
|
|
#define | VuoList_VuoInteger_TYPE_DEFINED |
|
#define | VuoList_VuoImage_TYPE_DEFINED |
|
typedef void * | VuoList_VuoInteger |
|
typedef void * | VuoList_VuoImage |
|