Changeset View
Changeset View
Standalone View
Standalone View
source/blender/gpu/gawain/immediate.c
| Context not available. | |||||
| data[1] = y; | data[1] = y; | ||||
| } | } | ||||
| void immAttrib2fv(unsigned attrib_id, const float data[2]) | |||||
| { | |||||
| immAttrib2f(attrib_id, data[0], data[1]); | |||||
| } | |||||
| void immAttrib3fv(unsigned attrib_id, const float data[3]) | void immAttrib3fv(unsigned attrib_id, const float data[3]) | ||||
| { | { | ||||
| immAttrib3f(attrib_id, data[0], data[1], data[2]); | immAttrib3f(attrib_id, data[0], data[1], data[2]); | ||||
| Context not available. | |||||
| glUniform1f(loc, x); | glUniform1f(loc, x); | ||||
| } | } | ||||
| void immUniform2fv(const char* name, const float pos[2]) | |||||
| { | |||||
| int loc = glGetUniformLocation(imm.bound_program, name); | |||||
| #if TRUST_NO_ONE | |||||
| assert(loc != -1); | |||||
| #endif | |||||
| glUniform2fv(loc, 1, pos); | |||||
| } | |||||
| void immUniform4fv(const char* name, const float pos[4]) | |||||
| { | |||||
| immUniform4f(name, pos[0], pos[1], pos[2], pos[3]); | |||||
| } | |||||
| void immUniform4f(const char* name, float x, float y, float z, float w) | void immUniform4f(const char* name, float x, float y, float z, float w) | ||||
| { | { | ||||
| int loc = glGetUniformLocation(imm.bound_program, name); | int loc = glGetUniformLocation(imm.bound_program, name); | ||||
| Context not available. | |||||