Examples of localToWorld()


Examples of com.ardor3d.scenegraph.Mesh.localToWorld()

            for (int x = 0; x < 3; x++) {
                vertices[x].subtract(t.getCenter(), vertices[x]);
                t.set(x, vertices[x]);
            }
            p.setTriangleModel(t);
            mesh.localToWorld(t.getCenter(), p.getPosition());
            p.getPosition().multiplyLocal(getInvScale());

        } else if (getParticleEmitter() instanceof MeshEmitter) {
            final MeshEmitter emitter = (MeshEmitter) getParticleEmitter();
            final Mesh mesh = emitter.getSource();
View Full Code Here

Examples of com.ardor3d.scenegraph.Mesh.localToWorld()

        } else if (getParticleEmitter() instanceof MeshEmitter) {
            final MeshEmitter emitter = (MeshEmitter) getParticleEmitter();
            final Mesh mesh = emitter.getSource();
            mesh.getMeshData().randomPointOnPrimitives(p.getPosition());
            mesh.localToWorld(p.getPosition(), p.getPosition());
            p.getPosition().multiplyLocal(getInvScale());
        } else {
            if (getParticleEmitter() != null) {
                getParticleEmitter().randomEmissionPoint(p.getPosition());
            } else {
View Full Code Here

Examples of com.ardor3d.scenegraph.Spatial.localToWorld()

        final Spatial picked = (Spatial) pickData.getTarget();
        if (picked instanceof Mesh && pickData.getIntersectionRecord().getNumberOfIntersections() > 0) {
            final PrimitiveKey key = pickData.getIntersectionRecord().getIntersectionPrimitive(0);
            ((Mesh) picked).getMeshData().getPrimitiveVertices(key.getPrimitiveIndex(), key.getSection(),
                    new Vector3[] { _calcVec3A, _calcVec3B, _calcVec3C });
            picked.localToWorld(_calcVec3A, _calcVec3A);
            picked.localToWorld(_calcVec3B, _calcVec3B);
            picked.localToWorld(_calcVec3C, _calcVec3C);
            final Vector3 loc = getNewOffset(oldMouse, current, camera, manager);
            final Transform transform = manager.getSpatialState().getTransform();
            transform.setTranslation(loc.addLocal(transform.getTranslation()));
View Full Code Here

Examples of com.ardor3d.scenegraph.Spatial.localToWorld()

        if (picked instanceof Mesh && pickData.getIntersectionRecord().getNumberOfIntersections() > 0) {
            final PrimitiveKey key = pickData.getIntersectionRecord().getIntersectionPrimitive(0);
            ((Mesh) picked).getMeshData().getPrimitiveVertices(key.getPrimitiveIndex(), key.getSection(),
                    new Vector3[] { _calcVec3A, _calcVec3B, _calcVec3C });
            picked.localToWorld(_calcVec3A, _calcVec3A);
            picked.localToWorld(_calcVec3B, _calcVec3B);
            picked.localToWorld(_calcVec3C, _calcVec3C);
            final Vector3 loc = getNewOffset(oldMouse, current, camera, manager);
            final Transform transform = manager.getSpatialState().getTransform();
            transform.setTranslation(loc.addLocal(transform.getTranslation()));
View Full Code Here

Examples of com.ardor3d.scenegraph.Spatial.localToWorld()

            final PrimitiveKey key = pickData.getIntersectionRecord().getIntersectionPrimitive(0);
            ((Mesh) picked).getMeshData().getPrimitiveVertices(key.getPrimitiveIndex(), key.getSection(),
                    new Vector3[] { _calcVec3A, _calcVec3B, _calcVec3C });
            picked.localToWorld(_calcVec3A, _calcVec3A);
            picked.localToWorld(_calcVec3B, _calcVec3B);
            picked.localToWorld(_calcVec3C, _calcVec3C);
            final Vector3 loc = getNewOffset(oldMouse, current, camera, manager);
            final Transform transform = manager.getSpatialState().getTransform();
            transform.setTranslation(loc.addLocal(transform.getTranslation()));

            // apply our filters, if any, now that we've made updates.
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.