Package com.ardor3d.renderer.state

Examples of com.ardor3d.renderer.state.CullState


        _lightState = new LightState();
        _lightState.setEnabled(true);
        _lightState.attach(light);
        nodes.getRootNode().setRenderState(_lightState);

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

        //proceduralTerrain.init(_canvas.getCanvasRenderer().getCamera(), nodes.getRootNode());
        voxelworld.init(_canvas.getCanvasRenderer().getCamera(), _passManager, nodes.getRootNode());
View Full Code Here


        _worldBound = new BoundingBox(Vector3.ZERO, Double.POSITIVE_INFINITY, Double.POSITIVE_INFINITY,
                Double.POSITIVE_INFINITY);

        getSceneHints().setRenderBucketType(RenderBucketType.Opaque);
        final CullState cs = new CullState();
        cs.setEnabled(true);
        cs.setCullFace(CullState.Face.Back);
        setRenderState(cs);

        final MaterialState materialState = new MaterialState();
        materialState.setAmbient(MaterialFace.FrontAndBack, new ColorRGBA(1, 1, 1, 1));
        materialState.setDiffuse(MaterialFace.FrontAndBack, new ColorRGBA(1, 1, 1, 1));
View Full Code Here

        final ZBufferState zState = new ZBufferState();
        zState.setEnabled(false);
        zState.setWritable(false);
        setRenderState(zState);

        final CullState cState = new CullState();
        cState.setEnabled(false);
        setRenderState(cState);

        final BlendState blend = new BlendState();
        blend.setBlendEnabled(true);
        blend.setSourceFunction(BlendState.SourceFunction.SourceAlpha);
View Full Code Here

    private final ZBufferState _transparentZBuff;

    public TransparentRenderBucket() {
        super();

        _tranparentCull = new CullState();
        _transparentZBuff = new ZBufferState();
        _transparentZBuff.setWritable(false);
        _transparentZBuff.setFunction(ZBufferState.TestFunction.LessThanOrEqualTo);

        _comparator = new TransparentComparator();
View Full Code Here

        _wireframeState = new WireframeState();
        _wireframeState.setFace(WireframeState.Face.FrontAndBack);
        _wireframeState.setLineWidth(DEFAULT_LINE_WIDTH);
        _wireframeState.setEnabled(true);

        _frontCull = new CullState();
        _frontCull.setCullFace(Face.Front);

        _backCull = new CullState();
        _backCull.setCullFace(Face.Back);

        _wireframeState.setAntialiased(antialiased);

        _noLights = new LightState();
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 Sphere sphere = new Sphere("Sphere", 8, 8, 1);
        sphere.setModelBound(new BoundingBox());
        sphere.getSceneHints().setDataMode(DataMode.VBO);

        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

        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

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

        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

                        (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

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.