Package org.jdesktop.wonderland.common.cell.state.PositionComponentServerState.Bounds

Examples of org.jdesktop.wonderland.common.cell.state.PositionComponentServerState.Bounds.BoundsType


     *
     * @param setup The cell's setup information
     * @return The bounds as a JME BoundingVolume object
     */
    public static BoundingVolume getCellBounds(PositionComponentServerState setup) {
        BoundsType type = setup.getBounds().type;
        float x = (float)setup.getBounds().x;
       
        if (type.equals(BoundsType.SPHERE) == true) {
            return new BoundingSphere(x, new Vector3f());
        }
        else if (type.equals(BoundsType.BOX) == true) {
            return new BoundingBox(new Vector3f(), x, (float)setup.getBounds().y, (float)setup.getBounds().z);
        }
       
        /* This should never happen, but in case it does... */
        throw new RuntimeException("Unsupported bounds type " + type);
View Full Code Here

TOP

Related Classes of org.jdesktop.wonderland.common.cell.state.PositionComponentServerState.Bounds.BoundsType

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.