|  |  |  | Cogl Reference Manual |  | 
|---|---|---|---|---|
| Top | Description | ||||
CoglHandle cogl_shader_ref (CoglHandle handle); void cogl_shader_unref (CoglHandle handle); CoglHandle cogl_program_ref (CoglHandle handle); void cogl_program_unref (CoglHandle handle); void cogl_program_use (CoglHandle handle); void cogl_program_uniform_1f (int uniform_no,float value); void cogl_program_uniform_1i (int uniform_no,int value); void cogl_program_uniform_float (int uniform_no,int size,int count,const float *value); void cogl_program_uniform_int (int uniform_no,int size,int count,const int *value); void cogl_program_uniform_matrix (int uniform_no,int size,int count,CoglBool transpose,const float *value);
CoglHandle          cogl_shader_ref                     (CoglHandle handle);
cogl_shader_ref has been deprecated since version 1.16 and should not be used in newly-written code. Use CoglSnippet api
Add an extra reference to a shader.
| 
 | A CoglHandle to a shader. | 
| Returns : | handle | 
void                cogl_shader_unref                   (CoglHandle handle);
cogl_shader_unref has been deprecated since version 1.16 and should not be used in newly-written code. Use CoglSnippet api
Removes a reference to a shader. If it was the last reference the shader object will be destroyed.
| 
 | A CoglHandle to a shader. | 
CoglHandle          cogl_program_ref                    (CoglHandle handle);
cogl_program_ref has been deprecated since version 1.16 and should not be used in newly-written code. Use CoglSnippet api
Add an extra reference to a program.
| 
 | A CoglHandle to a program. | 
| Returns : | handle | 
void                cogl_program_unref                  (CoglHandle handle);
cogl_program_unref has been deprecated since version 1.16 and should not be used in newly-written code. Use CoglSnippet api
Removes a reference to a program. If it was the last reference the program object will be destroyed.
| 
 | A CoglHandle to a program. | 
void                cogl_program_use                    (CoglHandle handle);
cogl_program_use has been deprecated since version 1.16 and should not be used in newly-written code. Use CoglSnippet api
Activate a specific shader program replacing that part of the GL
rendering pipeline, if passed in COGL_INVALID_HANDLE the default
behavior of GL is reinstated.
This function affects the global state of the current Cogl
context. It is much more efficient to attach the shader to a
specific material used for rendering instead by calling
cogl_material_set_user_program().
| 
 | a CoglHandle for a shader program or COGL_INVALID_HANDLE. | 
void cogl_program_uniform_1f (int uniform_no,float value);
cogl_program_uniform_1f has been deprecated since version 1.16 and should not be used in newly-written code. Use CoglSnippet api
Changes the value of a floating point uniform in the currently
used (see cogl_program_use()) shader program.
| 
 | the uniform to set. | 
| 
 | the new value of the uniform. | 
void cogl_program_uniform_1i (int uniform_no,int value);
cogl_program_uniform_1i has been deprecated since version 1.16 and should not be used in newly-written code. Use CoglSnippet api
Changes the value of an integer uniform in the currently
used (see cogl_program_use()) shader program.
| 
 | the uniform to set. | 
| 
 | the new value of the uniform. | 
void cogl_program_uniform_float (int uniform_no,int size,int count,const float *value);
cogl_program_uniform_float has been deprecated since version 1.16 and should not be used in newly-written code. Use CoglSnippet api
Changes the value of a float vector uniform, or uniform array in the
currently used (see cogl_program_use()) shader program.
| 
 | the uniform to set. | 
| 
 | Size of float vector. | 
| 
 | Size of array of uniforms. | 
| 
 | the new value of the uniform. [array length=count] | 
void cogl_program_uniform_int (int uniform_no,int size,int count,const int *value);
cogl_program_uniform_int has been deprecated since version 1.16 and should not be used in newly-written code. Use CoglSnippet api
Changes the value of a int vector uniform, or uniform array in the
currently used (see cogl_program_use()) shader program.
| 
 | the uniform to set. | 
| 
 | Size of int vector. | 
| 
 | Size of array of uniforms. | 
| 
 | the new value of the uniform. [array length=count] | 
void cogl_program_uniform_matrix (int uniform_no,int size,int count,CoglBool transpose,const float *value);
cogl_program_uniform_matrix has been deprecated since version 1.16 and should not be used in newly-written code. Use CoglSnippet api
Changes the value of a matrix uniform, or uniform array in the
currently used (see cogl_program_use()) shader program. The size
parameter is used to determine the square size of the matrix.
| 
 | the uniform to set. | 
| 
 | Size of matrix. | 
| 
 | Size of array of uniforms. | 
| 
 | Whether to transpose the matrix when setting the uniform. | 
| 
 | the new value of the uniform. [array length=count] |