Package aspect.render.shader

Examples of aspect.render.shader.ShaderProgram


    public Trail(Vector3 pos, Vector3 vel, final Frigate source) {

        if (shader == null) {
            Shader vert = loadShader(new File("shaders/test.vert"), Shader.Type.VERTEX);
            Shader frag = loadShader(new File("shaders/test.frag"), Shader.Type.FRAGMENT);
            shader = new ShaderProgram(vert, frag);
        }
       
        Material mtl = new Material(shader);
        model = ellipse(mtl, 2.0f, 2.0f, 20);
View Full Code Here


            fbo = new FrameBuffer(1024, 1024, p);
            fbo.setRepeat(false);
            fbo.setFilter(GL11.GL_NEAREST, GL11.GL_NEAREST);
            Shader vert = Shader.loadPrebuilt("texture.vert", Shader.Type.VERTEX);
            Shader frag = loadShader(new File("shaders/test.frag"), Shader.Type.FRAGMENT);
            post = new ShaderProgram(vert, frag);
            fbo.postProcess(post);
        } catch (LWJGLException ex) {
            Logger.getLogger(AspectTest.class.getName()).log(Level.SEVERE, null, ex);
        }
View Full Code Here

       
        Shader vertex = new Shader(new File("shaders/example.vert"), Type.VERTEX);
        Shader fragment1 = new Shader(new File("shaders/example1.frag"), Type.FRAGMENT);
        Shader fragment2 = new Shader(new File("shaders/example2.frag"), Type.FRAGMENT);
       
        shader1 = new ShaderProgram(vertex, fragment1);
        shader2 = new ShaderProgram(vertex, fragment2);
        try {
            frameBuffer = new FrameBuffer(128, 128, DEFAULT_CAMERA);
        } catch (Exception ex) {
            Logger.getLogger(ShaderDemo.class.getName()).log(Level.SEVERE, null, ex);
        }
View Full Code Here

                        m.shader = ShaderProgram.loadPrebuilt(args[2]);
                    } else {
                        Shader vert = loadShader(args[1], new File(args[1]), Shader.Type.VERTEX);
                        Shader frag = loadShader(args[2], new File(args[2]), Shader.Type.FRAGMENT);
                       
                        ShaderProgram shader = new ShaderProgram(vert, frag);
                       
                        m.shader = shader;
                    }
                    break;
                }
View Full Code Here

TOP

Related Classes of aspect.render.shader.ShaderProgram

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.