Tweak zclip demo

This commit is contained in:
Luke Benstead 2019-03-25 18:51:36 +00:00
parent 7e47b21fb5
commit e0613faced

View File

@ -252,15 +252,17 @@ void DrawGLScene()
static float z = 0.0f; static float z = 0.0f;
static char increasing = 1; static char increasing = 1;
const float max = 50.0f;
if(increasing) { if(increasing) {
z += 10.0f; z += 1.0f;
} else { } else {
z -= 10.0f; z -= 1.0f;
} }
if(z > 10.0f) { if(z > max) {
increasing = !increasing; increasing = !increasing;
z = 10.0f; z = max;
} }
if(z < 0.0f) { if(z < 0.0f) {