Example usage for org.lwjgl.opengl GL12 GL_LIGHT_MODEL_COLOR_CONTROL

List of usage examples for org.lwjgl.opengl GL12 GL_LIGHT_MODEL_COLOR_CONTROL

Introduction

In this page you can find the example usage for org.lwjgl.opengl GL12 GL_LIGHT_MODEL_COLOR_CONTROL.

Prototype

int GL_LIGHT_MODEL_COLOR_CONTROL

To view the source code for org.lwjgl.opengl GL12 GL_LIGHT_MODEL_COLOR_CONTROL.

Click Source Link

Document

Accepted by the pname parameter of LightModel*, and also by the pname parameter of GetBooleanv, GetIntegerv, GetFloatv, and GetDoublev.

Usage

From source file:com.ardor3d.scene.state.lwjgl.LwjglLightStateUtil.java

License:Open Source License

private static void setSpecularControl(final boolean separateSpecularOn, final LightStateRecord record) {
    if (!record.isValid() || record.isSeparateSpecular() != separateSpecularOn) {
        if (separateSpecularOn) {
            GL11.glLightModeli(GL12.GL_LIGHT_MODEL_COLOR_CONTROL, GL12.GL_SEPARATE_SPECULAR_COLOR);
        } else {/*from w  w  w  .j  a va2 s. com*/
            GL11.glLightModeli(GL12.GL_LIGHT_MODEL_COLOR_CONTROL, GL12.GL_SINGLE_COLOR);
        }
        record.setSeparateSpecular(separateSpecularOn);
    }
}

From source file:jpcsp.graphics.RE.RenderingEngineLwjgl.java

License:Open Source License

@Override
public void setLightMode(int mode) {
    GL11.glLightModeli(GL12.GL_LIGHT_MODEL_COLOR_CONTROL, lightModeToGL[mode]);
}