mirror of
https://git.davidovski.xyz/glsl-mandelbrot.git
synced 2024-08-15 00:43:35 +00:00
changed uniforms to use shader_
This commit is contained in:
parent
6a47da4a1e
commit
6507f80a3d
1 changed files with 8 additions and 8 deletions
16
brotshader.c
16
brotshader.c
|
@ -23,10 +23,10 @@ int main() {
|
||||||
|
|
||||||
float screen[2] = {(float)width, (float)height};
|
float screen[2] = {(float)width, (float)height};
|
||||||
|
|
||||||
SetShaderValue(shader, resolutionLoc, screen, UNIFORM_VEC2);
|
SetShaderValue(shader, resolutionLoc, screen, SHADER_UNIFORM_VEC2);
|
||||||
SetShaderValue(shader, locationLoc, &offset, UNIFORM_VEC2);
|
SetShaderValue(shader, locationLoc, &offset, SHADER_UNIFORM_VEC2);
|
||||||
SetShaderValue(shader, zoomLoc, &zoom, UNIFORM_FLOAT);
|
SetShaderValue(shader, zoomLoc, &zoom, SHADER_UNIFORM_FLOAT);
|
||||||
SetShaderValue(shader, maxLoc, &max, UNIFORM_INT);
|
SetShaderValue(shader, maxLoc, &max, SHADER_UNIFORM_INT);
|
||||||
|
|
||||||
SetTargetFPS(60);
|
SetTargetFPS(60);
|
||||||
|
|
||||||
|
@ -42,10 +42,10 @@ int main() {
|
||||||
if (IsKeyDown(KEY_A)) max -= 1;
|
if (IsKeyDown(KEY_A)) max -= 1;
|
||||||
if (IsKeyDown(KEY_D)) max += 1;
|
if (IsKeyDown(KEY_D)) max += 1;
|
||||||
|
|
||||||
SetShaderValue(shader, resolutionLoc, screen, UNIFORM_VEC2);
|
SetShaderValue(shader, resolutionLoc, screen, SHADER_UNIFORM_VEC2);
|
||||||
SetShaderValue(shader, locationLoc, &offset, UNIFORM_VEC2);
|
SetShaderValue(shader, locationLoc, &offset, SHADER_UNIFORM_VEC2);
|
||||||
SetShaderValue(shader, zoomLoc, &zoom, UNIFORM_FLOAT);
|
SetShaderValue(shader, zoomLoc, &zoom, SHADER_UNIFORM_FLOAT);
|
||||||
SetShaderValue(shader, maxLoc, &max, UNIFORM_INT);
|
SetShaderValue(shader, maxLoc, &max, SHADER_UNIFORM_INT);
|
||||||
|
|
||||||
BeginDrawing();
|
BeginDrawing();
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue