mirror of
https://github.com/processing/processing4.git
synced 2026-02-12 01:50:44 +01:00
fixes bug #958, darker drawing with opengl
This commit is contained in:
@@ -1976,6 +1976,7 @@ public class PGraphicsOpenGL extends PGraphics3D {
|
||||
|
||||
|
||||
protected void ambientFromCalc() {
|
||||
super.ambientFromCalc();
|
||||
calcColorBuffer();
|
||||
gl.glMaterialfv(GL.GL_FRONT_AND_BACK, GL.GL_AMBIENT, colorBuffer, 0);
|
||||
}
|
||||
@@ -2003,6 +2004,7 @@ public class PGraphicsOpenGL extends PGraphics3D {
|
||||
|
||||
|
||||
protected void specularFromCalc() {
|
||||
super.specularFromCalc();
|
||||
calcColorBuffer();
|
||||
gl.glMaterialfv(GL.GL_FRONT_AND_BACK, GL.GL_SPECULAR, colorBuffer, 0);
|
||||
}
|
||||
@@ -2036,6 +2038,7 @@ public class PGraphicsOpenGL extends PGraphics3D {
|
||||
|
||||
|
||||
protected void emissiveFromCalc() {
|
||||
super.emissiveFromCalc();
|
||||
calcColorBuffer();
|
||||
gl.glMaterialfv(GL.GL_FRONT_AND_BACK, GL.GL_EMISSION, colorBuffer, 0);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user