GPU: Rename GPU_shader_get_uniform to GPU_shader_get_uniform_ensure
This is in order to make the API more multithread friendly inside the draw manager. GPU_shader_get_uniform will only serve to query the shader interface and not do any GL call, making it threadsafe. For now it only print a warning if the uniform was not queried before.
This commit is contained in:
@@ -94,6 +94,7 @@ GPUShaderInterface *GPU_shaderinterface_create(int32_t program_id);
|
||||
void GPU_shaderinterface_discard(GPUShaderInterface *);
|
||||
|
||||
const GPUShaderInput *GPU_shaderinterface_uniform(const GPUShaderInterface *, const char *name);
|
||||
const GPUShaderInput *GPU_shaderinterface_uniform_ensure(const GPUShaderInterface *, const char *name);
|
||||
const GPUShaderInput *GPU_shaderinterface_uniform_builtin(const GPUShaderInterface *, GPUUniformBuiltin);
|
||||
const GPUShaderInput *GPU_shaderinterface_ubo(const GPUShaderInterface *, const char *name);
|
||||
const GPUShaderInput *GPU_shaderinterface_attr(const GPUShaderInterface *, const char *name);
|
||||
|
Reference in New Issue
Block a user