Package fcagnin.jglsdk.glutil

Examples of fcagnin.jglsdk.glutil.MatrixStack.pop()


                glDepthMask( true );
                glEnable( GL_DEPTH_TEST );
                glUniform4f( unlit.objectColorUnif, 1.0f, 1.0f, 1.0f, 1.0f );
                scene.getCubeMesh().render( "flat" );

                modelMatrix.pop();
            }

            modelMatrix.pop();
        }
    }
View Full Code Here


                scene.getCubeMesh().render( "flat" );

                modelMatrix.pop();
            }

            modelMatrix.pop();
        }
    }

    @Override
    protected void reshape(int w, int h) {
View Full Code Here

        {
            modelMatrix.push();

            scene.draw( modelMatrix, materialBlockIndex, lights.getTimerValue( "tetra" ) );

            modelMatrix.pop();
        }

        {
            modelMatrix.push();
View Full Code Here

                Vec4 lightColor = lights.getSunlightIntensity();
                glUniform4( unlit.objectColorUnif, lightColor.fillAndFlipBuffer( vec4Buffer ) );
                scene.getSphereMesh().render( "flat" );

                modelMatrix.pop();
            }

            // Render the lights
            {
                for ( int light = 0; light < lights.getNumberOfPointLights(); light++ ) {
View Full Code Here

                    Vec4 lightColor = lights.getPointLightIntensity( light );
                    glUniform4( unlit.objectColorUnif, lightColor.fillAndFlipBuffer( vec4Buffer ) );
                    scene.getCubeMesh().render( "flat" );

                    modelMatrix.pop();
                }
            }

            if ( drawCameraPos ) {
                modelMatrix.push();
View Full Code Here

                glDepthMask( true );
                glEnable( GL_DEPTH_TEST );
                glUniform4f( unlit.objectColorUnif, 1.0f, 1.0f, 1.0f, 1.0f );
                scene.getCubeMesh().render( "flat" );

                modelMatrix.pop();
            }

            modelMatrix.pop();
        }
    }
View Full Code Here

                scene.getCubeMesh().render( "flat" );

                modelMatrix.pop();
            }

            modelMatrix.pop();
        }
    }

    @Override
    protected void reshape(int w, int h) {
View Full Code Here

        glBindSampler( colorTexUnit, 0 );
        glBindTexture( GL_TEXTURE_2D, 0 );

        glUseProgram( 0 );

        modelMatrix.pop();

        // Render the sun
        {
            modelMatrix.push();
View Full Code Here

            Vec4 lightColor = lightEnv.getSunlightScaledIntensity();
            glUniform4( progUnlit.objectColorUnif, lightColor.fillAndFlipBuffer( vec4Buffer ) );
            sphere.render( "flat" );

            modelMatrix.pop();
        }

        // Draw lights
        for ( int light = 0; light < lightEnv.getNumPointLights(); light++ ) {
            modelMatrix.push();
View Full Code Here

            Vec4 lightColor = lightEnv.getPointLightScaledIntensity( light );
            glUniform4( progUnlit.objectColorUnif, lightColor.fillAndFlipBuffer( vec4Buffer ) );
            sphere.render( "flat" );

            modelMatrix.pop();
        }

        if ( drawCameraPos ) {
            modelMatrix.push();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.