Added rlglDraw() to SetShaderValueV()
Usually if you update shader values, they will only take effect when starting a new shader mode because that's when the draw function is called. By calling it when changing shader values, you ensure the changes take place instantly. This makes it way simpler to do palette swapping and other "dynamic" shader functions.
This commit is contained in:
parent
6f2f09947f
commit
654d3a29e2
|
|
@ -3093,6 +3093,8 @@ void SetShaderValueV(Shader shader, int uniformLoc, const void *value, int unifo
|
|||
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
|
||||
glUseProgram(shader.id);
|
||||
|
||||
rlglDraw(); // Force draw
|
||||
|
||||
switch (uniformType)
|
||||
{
|
||||
case UNIFORM_FLOAT: glUniform1fv(uniformLoc, count, (float *)value); break;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user