Package com.ardor3d.renderer.state

Examples of com.ardor3d.renderer.state.CullState


        t.getSceneHints().setRenderBucketType(RenderBucketType.Ortho);
        t.getSceneHints().setLightCombineMode(LightCombineMode.Off);
        t.setTranslation(new Vector3(0, 20, 0));
        _root.attachChild(t);

        final CullState cs = new CullState();
        cs.setCullFace(CullState.Face.Back);
        cs.setEnabled(true);
        _root.setRenderState(cs);

        final TextureState ts = new TextureState();
        ts.setEnabled(true);
        ts.setTexture(TextureManager.load("images/ardor3d_white_256.jpg", Texture.MinificationFilter.Trilinear,
View Full Code Here


        final ZBufferState zs = new ZBufferState();
        zs.setWritable(false);
        trailMesh.setRenderState(zs);

        final CullState cs = new CullState();
        cs.setCullFace(CullState.Face.None);
        cs.setEnabled(true);
        trailMesh.setRenderState(cs);

        _root.attachChild(trailMesh);

        final Box box = new Box("Box", new Vector3(0, 0, 0), 1000, 1, 1000);
View Full Code Here

        rotate.fromAngleNormalAxis(-Math.PI / 2, Vector3.UNIT_X);
        zup.setRotation(rotate);

        final Node textMoveNode = new Node("textModeNode");

        final CullState cs = new CullState();
        cs.setCullFace(Face.Back);
        textMoveNode.setRenderState(cs);

        final Node textExampleNode = new Node("textExampleNode");
        textExampleNode.setTranslation(0, 0, 0);
        final double a = 9.0;
View Full Code Here

                        (float) _canvas.getCanvasRenderer().getCamera().getWidth()
                                / (float) _canvas.getCanvasRenderer().getCamera().getHeight(), 1, farPlane);
        _canvas.getCanvasRenderer().getCamera().lookAt(new Vector3(0, 0, 0), Vector3.UNIT_Y);

        // Setup some standard states for the scene.
        final CullState cullFrontFace = new CullState();
        cullFrontFace.setEnabled(true);
        cullFrontFace.setCullFace(CullState.Face.Back);
        _root.setRenderState(cullFrontFace);

        final TextureState ts = new TextureState();
        ts.setEnabled(true);
        ts.setTexture(TextureManager.load("images/ardor3d_white_256.jpg", Texture.MinificationFilter.Trilinear, true));
View Full Code Here

        _canvas.getCanvasRenderer().getCamera().lookAt(new Vector3(0, 0, 0), Vector3.UNIT_Y);

        _controlHandle.setMoveSpeed(200);

        // Setup some standard states for the scene.
        final CullState cullFrontFace = new CullState();
        cullFrontFace.setEnabled(true);
        cullFrontFace.setCullFace(CullState.Face.Back);
        _root.setRenderState(cullFrontFace);

        final TextureState ts = new TextureState();
        ts.setEnabled(true);
        ts.setTexture(TextureManager.load("images/ardor3d_white_256.jpg", Texture.MinificationFilter.Trilinear, true));
View Full Code Here

        billboard.getSceneHints().setRenderBucketType(RenderBucketType.Transparent);

        final Quad q1 = new Quad("font block", 150, 200);
        q1.setTranslation(0, 80, 0);
        q1.setModelBound(new BoundingBox());
        final CullState cs = new CullState();
        cs.setCullFace(CullState.Face.None);
        q1.setRenderState(cs);
        billboard.attachChild(q1);

        final TextureState ts = new TextureState();
        ts.setEnabled(true);
View Full Code Here

        t.getSceneHints().setRenderBucketType(RenderBucketType.Ortho);
        t.getSceneHints().setLightCombineMode(LightCombineMode.Off);
        t.setTranslation(new Vector3(0, 20, 0));
        _root.attachChild(t);

        final CullState cs = new CullState();
        cs.setCullFace(CullState.Face.Back);
        cs.setEnabled(true);
        _root.setRenderState(cs);

        final MaterialState ms = new MaterialState();
        ms.setColorMaterial(ColorMaterial.Diffuse);
        _root.setRenderState(ms);
View Full Code Here

        dLight.setSpecular(new ColorRGBA(0.3f, 0.3f, 0.2f, 1));
        dLight.setDirection(new Vector3(-1, -1, -1).normalizeLocal());
        _lightState.attach(dLight);
        _lightState.setEnabled(true);

        final CullState cs = new CullState();
        cs.setEnabled(true);
        cs.setCullFace(CullState.Face.Back);
        _root.setRenderState(cs);

        final FogState fs = new FogState();
        fs.setStart(farPlane / 2.0f);
        fs.setEnd(farPlane);
View Full Code Here

        dLight.setSpecular(new ColorRGBA(0.3f, 0.3f, 0.2f, 1));
        dLight.setDirection(new Vector3(-1, -1, -1).normalizeLocal());
        _lightState.attach(dLight);
        _lightState.setEnabled(true);

        final CullState cs = new CullState();
        cs.setEnabled(true);
        cs.setCullFace(CullState.Face.Back);
        _root.setRenderState(cs);

        final FogState fs = new FogState();
        fs.setStart(farPlane / 2.0f);
        fs.setEnd(farPlane);
View Full Code Here

            final NvTriangleStripper stripper = new NvTriangleStripper();
            stripper.setReorderVertices(true);
            primeModel.acceptVisitor(stripper, true);

            // OPTIMIZATION: don't draw surfaces that face away from the camera...
            final CullState cullState = new CullState();
            cullState.setCullFace(Face.Back);
            primeModel.setRenderState(cullState);

            for (int i = 0; i < 10; i++) {
                for (int j = 0; j < 10; j++) {
                    // Add copy of model
View Full Code Here

TOP

Related Classes of com.ardor3d.renderer.state.CullState

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.