Package com.jme3.math

Examples of com.jme3.math.Vector2f.normalize()


        }

        newUp.set(newDirection).crossLocal(newLeft).normalizeLocal();
       
    Quaternion r = new Quaternion().fromAxes(newLeft, newUp, newDirection);
    r.normalize();
    this.setLocalRotation(r);   
  }

}
View Full Code Here


  }

   public Vector2f GetDirection()
  {
     Vector2f Direction = (m_PointB.subtract(m_PointA));
    return Direction.normalize();
//    return Direction;
  }

  void ComputeNormal()
  {
View Full Code Here

   */
  void ProjectPathOnCellWall(int SideNumber, Line2D MotionPath) {
    // compute the normalized vector of the cell wall in question
    Vector2f WallNormal = m_Side[SideNumber].EndPointB().subtract(
        m_Side[SideNumber].EndPointA());
    WallNormal = WallNormal.normalize();

    // determine the vector of our current movement
    Vector2f MotionVector = MotionPath.EndPointB().subtract(
        MotionPath.EndPointA());

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.