Package utility

Examples of utility.EulerCamera$Builder


            System.err.println("The display wasn't initialized correctly. :(");
            Display.destroy();
            System.exit(1);
        }

        EulerCamera cam = new EulerCamera((float) Display.getWidth() / (float) Display.getHeight(), -2.19f, 1.36f,
                11.45f);
        cam.setFieldOfView(60);
        cam.applyPerspectiveMatrix();

        setUpShaders();
        setUpLighting();
        setUpDisplayLists();

        while (!Display.isCloseRequested()) {
            glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);

            glLoadIdentity();
            cam.applyTranslations();

            glUseProgram(shaderProgram);
            glCallList(bunny);
            glUseProgram(0);

            cam.processMouse(1, 80, -80);
            cam.processKeyboard(16, 1, 1, 1);

            if (Mouse.isButtonDown(0)) {
                Mouse.setGrabbed(true);
            } else if (Mouse.isButtonDown(1)) {
                Mouse.setGrabbed(false);
View Full Code Here


            System.err.println("The display wasn't initialized correctly. :(");
            Display.destroy();
            System.exit(1);
        }

        EulerCamera cam = new EulerCamera((float) Display.getWidth() / (float) Display.getHeight(), -2.19f, 1.36f,
                11.45f);
        cam.setFieldOfView(60);
        cam.applyPerspectiveMatrix();

        setUpShaders();
        setUpLighting();
        setUpDisplayLists();

        while (!Display.isCloseRequested()) {
            glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);

            glLoadIdentity();
            cam.applyTranslations();

            glUseProgram(shaderProgram);
            glCallList(bunny);
            glUseProgram(0);

            if (Mouse.isGrabbed()) {
                cam.processMouse(1, 80, -80);
            }
            cam.processKeyboard(16, 1, 1, 1);

            if (Mouse.isButtonDown(0)) {
                Mouse.setGrabbed(true);
            } else if (Mouse.isButtonDown(1)) {
                Mouse.setGrabbed(false);
View Full Code Here

TOP

Related Classes of utility.EulerCamera$Builder

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.