Package com.jme3.bounding

Examples of com.jme3.bounding.BoundingBox.computeFromPoints()


   */
  public static BoundingBox getAABoundingBox(Geometry g)
    {
    VertexBuffer posBuffer = g.getMesh().getBuffer(Type.Position);
    BoundingBox bb = new BoundingBox();
    bb.computeFromPoints((FloatBuffer)posBuffer.getData());

    return bb;
    }
  }
View Full Code Here


        build();
    }
   
    private void build() {
        BoundingSphere bs = new BoundingSphere();
        bs.computeFromPoints(mesh.getFloatBuffer(VertexBuffer.Type.Position));
        meshBoundingSphereRadius = bs.getRadius();
        List<Vertex> vertexLookup = new ArrayList<Vertex>();
        initialize();
       
        gatherVertexData(mesh, vertexLookup);
View Full Code Here

   */
  public static BoundingSphere getBoundingSphere(Geometry g)
    {
    VertexBuffer posBuffer = g.getMesh().getBuffer(Type.Position);
    BoundingSphere bs = new BoundingSphere();
    bs.computeFromPoints((FloatBuffer)posBuffer.getData());

    return bs;
    }
  /**
   * Calculates the Axis Aligned Bounding Box for a Geometry
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.