Package com.ardor3d.scenegraph.shape

Examples of com.ardor3d.scenegraph.shape.Pyramid


        attachChild(base);
        base.updateModelBound();

        // Add the pyramid tip.
        final double tipLength = _length / 2.0;
        final Pyramid tip = new Pyramid("tip", 2 * _width, tipLength);
        tip.getMeshData().translatePoints(0, _tipGap + _length + 0.5 * tipLength, 0);
        tip.getMeshData().rotatePoints(InteractArrow.rotator);
        tip.getMeshData().rotateNormals(InteractArrow.rotator);

        attachChild(tip);
        tip.updateModelBound();

    }
View Full Code Here


        addMesh(new Hexagon("Hexagon", 3));
        addMesh(new Icosahedron("Icosahedron", 3));
        addMesh(new MultiFaceBox("MultiFaceBox", new Vector3(), 3, 3, 3));
        addMesh(new Octahedron("Octahedron", 3));
        addMesh(new PQTorus("PQTorus", 5, 4, 1.5, .5, 128, 8));
        addMesh(new Pyramid("Pyramid", 2, 4));
        addMesh(new Quad("Quad", 3, 3));
        addMesh(new RoundedBox("RoundedBox", new Vector3(3, 3, 3)));
        addMesh(new Sphere("Sphere", 16, 16, 3));
        addMesh(new GeoSphere("GeoSphere", true, 3, 3, TextureMode.Original));
        addMesh(new StripBox("StripBox", new Vector3(), 3, 3, 3));
View Full Code Here

        final TextureState ts = new TextureState();
        ts.setTexture(TextureManager.load("images/ardor3d_white_256.jpg", Texture.MinificationFilter.Trilinear, true));
        sp.setRenderState(ts);

        // add some scenery
        final Pyramid b = new Pyramid("box", 2, 3);
        b.setRotation(new Quaternion().fromAngleNormalAxis(MathUtils.PI, Vector3.UNIT_X));
        b.addController(new SpatialController<Spatial>() {
            public void update(final double time, final Spatial caller) {
                b.setTranslation(-3, 6 * MathUtils.sin(_timer.getTimeInSeconds()), 0);
            };
        });
        _root.attachChild(b);

        // add base texture to unit 0
        final TextureState ts2 = new TextureState();
        ts2.setTexture(TextureManager.load("images/ardor3d_white_256.jpg", Texture.MinificationFilter.Trilinear, true));
        b.setRenderState(ts2);
    }
View Full Code Here

        addMesh(new Hexagon("Hexagon", 3));
        addMesh(new Icosahedron("Icosahedron", 3));
        addMesh(new MultiFaceBox("MultiFaceBox", new Vector3(), 3, 3, 3));
        addMesh(new Octahedron("Octahedron", 3));
        addMesh(new PQTorus("PQTorus", 5, 4, 1.5, .5, 128, 8));
        addMesh(new Pyramid("Pyramid", 2, 4));
        addMesh(new Quad("Quad", 3, 3));
        addMesh(new RoundedBox("RoundedBox", new Vector3(3, 3, 3)));
        addMesh(new Sphere("Sphere", 16, 16, 3));
        addMesh(new GeoSphere("GeoSphere", true, 3, 3, TextureMode.Original));
        addMesh(new StripBox("StripBox", new Vector3(), 3, 3, 3));
View Full Code Here

TOP

Related Classes of com.ardor3d.scenegraph.shape.Pyramid

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.