ref: 3da29a050385acdcf7e33fc30abbfc654d388f9a
parent: 3c2622aa007b32a3c1e11ea6532c42c2481aca3f
author: David <gek@katherine>
date: Wed Feb 17 08:20:02 EST 2021
Gears demo improvement
--- a/SDL_Examples/gears.c
+++ b/SDL_Examples/gears.c
@@ -243,6 +243,7 @@
int winSizeY = 480;
unsigned int fps = 0;
unsigned int flat = 0;
+ unsigned int setenspec = 1;
unsigned int blending = 0;
char needsRGBAFix = 0;
if (argc > 1) {
@@ -260,6 +261,8 @@
flat = 0;
if (!strcmp(argv[i],"-blend"))
blending = 1;
+ if (!strcmp(argv[i],"-nospecular"))
+ setenspec = 0;
larg = argv[i];
}
}
@@ -367,7 +370,7 @@
glTranslatef(0.0, 0.0, -45.0);
initScene();
-
+ if(setenspec) glSetEnableSpecular(GL_TRUE); else glSetEnableSpecular(GL_FALSE);
// variables for timing:
unsigned int frames = 0;
unsigned int tNow = SDL_GetTicks();
--- a/include/zbuffer.h
+++ b/include/zbuffer.h
@@ -122,7 +122,7 @@
dest = RGB_TO_PIXEL(sr,sg,sb); \
break; \
\
- }
+ }