made lighting more subtle

Thu, 15 Feb 2018 12:19:10 +0200

author
Santeri Piippo
date
Thu, 15 Feb 2018 12:19:10 +0200
changeset 1248
8059668a2cf3
parent 1247
7e1ce2fc066b
child 1249
6a8f76f0f4d1

made lighting more subtle

src/glrenderer.cpp file | annotate | diff | comparison | revisions
--- a/src/glrenderer.cpp	Thu Feb 15 12:18:57 2018 +0200
+++ b/src/glrenderer.cpp	Thu Feb 15 12:19:10 2018 +0200
@@ -259,10 +259,11 @@
 {
 	GLfloat materialShininess[] = {5.0};
 	GLfloat lightPosition[] = {1.0, 1.0, 1.0, 0.0};
-	GLfloat ambientLightingLevel[] = {0.8, 0.8, 0.8, 1.0};
+	GLfloat ambientLightingLevel[] = {0.5, 0.5, 0.5, 1.0};
 	glShadeModel(GL_SMOOTH);
 	glMaterialfv(GL_FRONT, GL_SHININESS, materialShininess);
-	glMaterialfv(GL_FRONT, GL_AMBIENT, ambientLightingLevel);
+	glLightfv(GL_LIGHT0, GL_AMBIENT, ambientLightingLevel);
+	glLightfv(GL_LIGHT0, GL_DIFFUSE, ambientLightingLevel);
 	glLightfv(GL_LIGHT0, GL_POSITION, lightPosition);
 	glEnable(GL_LIGHTING);
 	glEnable(GL_LIGHT0);

mercurial