Package fcagnin.jgltut.tut12

Examples of fcagnin.jgltut.tut12.Scene


    private FloatBuffer lightBlockBuffer = BufferUtils.createFloatBuffer( LightBlock.SIZE );


    private void initializePrograms() {
        for ( int progIndex = 0; progIndex < LightingProgramTypes.MAX_LIGHTING_PROGRAM_TYPES.ordinal(); progIndex++ ) {
            programs[progIndex] = new ProgramData();
            programs[progIndex] = loadLitProgram( shaderFileNames[progIndex].vertexShaderFileName,
                    shaderFileNames[progIndex].fragmentShaderFileName );
        }

        unlit = loadUnlitProgram( "PosTransform.vert", "UniformColor.frag" );
View Full Code Here


    private ProgramData loadLitProgram(String vertexShaderFileName, String fragmentShaderFileName) {
        ArrayList<Integer> shaderList = new ArrayList<>();
        shaderList.add( Framework.loadShader( GL_VERTEX_SHADER, vertexShaderFileName ) );
        shaderList.add( Framework.loadShader( GL_FRAGMENT_SHADER, fragmentShaderFileName ) );

        ProgramData data = new ProgramData();
        data.theProgram = Framework.createProgram( shaderList );
        data.modelToCameraMatrixUnif = glGetUniformLocation( data.theProgram, "modelToCameraMatrix" );

        data.normalModelToCameraMatrixUnif = glGetUniformLocation( data.theProgram, "normalModelToCameraMatrix" );
View Full Code Here

    private FloatBuffer lightBlockBuffer = BufferUtils.createFloatBuffer( LightBlock.SIZE );


    private void initializePrograms() {
        for ( int progIndex = 0; progIndex < LightingProgramTypes.MAX_LIGHTING_PROGRAM_TYPES.ordinal(); progIndex++ ) {
            programs[progIndex] = new ProgramData();
            programs[progIndex] = loadLitProgram( shaderFileNames[progIndex].vertexShaderFileName,
                    shaderFileNames[progIndex].fragmentShaderFileName );
        }

        unlit = loadUnlitProgram( "PosTransform.vert", "UniformColor.frag" );
View Full Code Here

    private ProgramData loadLitProgram(String vertexShaderFileName, String fragmentShaderFileName) {
        ArrayList<Integer> shaderList = new ArrayList<>();
        shaderList.add( Framework.loadShader( GL_VERTEX_SHADER, vertexShaderFileName ) );
        shaderList.add( Framework.loadShader( GL_FRAGMENT_SHADER, fragmentShaderFileName ) );

        ProgramData data = new ProgramData();
        data.theProgram = Framework.createProgram( shaderList );
        data.modelToCameraMatrixUnif = glGetUniformLocation( data.theProgram, "modelToCameraMatrix" );

        data.normalModelToCameraMatrixUnif = glGetUniformLocation( data.theProgram, "normalModelToCameraMatrix" );
View Full Code Here

                            new GaussianSpecularLighting().start();
                            break;

                        case "Scene Lighting":
                            Framework.CURRENT_TUTORIAL_DATAPATH = "/fcagnin/jgltut/tut12/data/";
                            new SceneLighting().start( 700, 700 );
                            break;
                        case "HDR Lighting":
                            Framework.CURRENT_TUTORIAL_DATAPATH = "/fcagnin/jgltut/tut12/data/";
                            new HDRLighting().start( 700, 700 );
                            break;
View Full Code Here

TOP

Related Classes of fcagnin.jgltut.tut12.Scene

Copyright © 2018 www.massapicom. 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.