Package com.jme.math

Examples of com.jme.math.Matrix3f


        return loadedModel;
    }

    // This gimble locks, but good enough for now...
    public static Matrix3f calcRotationMatrix(float x, float y, float z) {
        Matrix3f m3f = new Matrix3f();
        m3f.loadIdentity();
        m3f.fromAngleAxis(x, new Vector3f(1f, 0f, 0f));
        Matrix3f rotY = new Matrix3f();
        rotY.loadIdentity();
        rotY.fromAngleAxis(y, new Vector3f(0f, 1f, 0f));
        Matrix3f rotZ = new Matrix3f();
        rotZ.loadIdentity();
        rotZ.fromAngleAxis(z, new Vector3f(0f, 0f, 1f));

        m3f.multLocal(rotY);
        m3f.multLocal(rotZ);

        return m3f;
View Full Code Here


                        label = new TextLabel2D(displayName, foregroundColor, backgroundColor,
          height, true, font);

                        label.setLocalTranslation(0, heightAbove, 0);

                        Matrix3f rot = new Matrix3f();
                        rot.fromAngleAxis((float) Math.PI, new Vector3f(0f, 1f, 0f));
                        label.setLocalRotation(rot);

                        attachChild(label);
                    } else {
                        label.setFont(font);
View Full Code Here

TOP

Related Classes of com.jme.math.Matrix3f

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.