Examples of Point3d


Examples of com.cedarsoftware.ncube.proximity.Point3D

            String twoDoubleFormat = "\"%f,%f\"";
            builder.append(String.format(twoDoubleFormat, l.getX(), l.getY()));
        }
        else if (o instanceof Point3D)
        {
            Point3D p = (Point3D)o;
            builder.append(String.format("\"%f,%f,%f\"", p.getX(), p.getY(), p.getZ()));
        }
        else if (o instanceof Range)
        {
            Range r = (Range)o;
            startArray();
View Full Code Here

Examples of com.l2jfrozen.util.Point3D

    if (player.isInBoat())
    {
      if (player.getBoat().getObjectId() == _boatId)
      {
        player.setInBoatPosition(new Point3D(_x, _y, _z));
        player.getPosition().setHeading(_heading);
        player.broadcastPacket(new StopMoveInVehicle(player, _boatId));
      }
    }
  }
View Full Code Here

Examples of graphics.common.Point3D

    }

    private static class Get3D implements GetPoint {
        @Override
        public Point get( double x, double y, double z ) {
                return new Point3D( x, y, z );
        }
View Full Code Here

Examples of javafx.geometry.Point3D

    @Override
    public void stepSimulation() {
        if(state==BombState.ACTIVE){
            bombPhysicalObject.stepSimulation();
            Quat4d q = bombPhysicalObject.getOrientation();
            rotate.setAxis(new Point3D(q.x, q.y, q.z));
            double radians = Math.acos(q.w) * 2;
            rotate.setAngle(Math.toDegrees(radians));

            Vector3d place = bombPhysicalObject.getPlace();
            setTranslateX(place.getX());
View Full Code Here

Examples of javax.vecmath.Point3d

        // TODO use light factories

        AmbientLight alight = new AmbientLight(true,new Color3f(0.5f,0.5f,0.5f));
        alight.setEnable(true);
        rootGroup.addChild(alight);
        BoundingSphere bounds = new BoundingSphere (new Point3d (0, 0.0, 0), 1E100);
        alight.setInfluencingBounds(bounds);

        lights = new DirectionalLight[1];

        for (int i=0; i<lights.length; ++i) {
View Full Code Here

Examples of javax.vecmath.Point3d

        // TODO use light factories

        AmbientLight alight = new AmbientLight(true,new Color3f(0.5f,0.5f,0.5f));
        alight.setEnable(true);
        rootGroup.addChild(alight);
        BoundingSphere bounds = new BoundingSphere (new Point3d (0, 0.0, 0), 1E100);
        alight.setInfluencingBounds(bounds);

        lights = new DirectionalLight[1];

        for (int i=0; i<lights.length; ++i) {
View Full Code Here

Examples of javax.vecmath.Point3d

        TransformGroup objTrans = new TransformGroup();
        Transform3D t3dTrans = new Transform3D();
        objTrans.setCapability(TransformGroup.ALLOW_TRANSFORM_WRITE);
        objTrans.setTransform(t3dTrans);
        objRoot.addChild(objTrans);
        BoundingSphere bounds = new BoundingSphere(new Point3d(0.0, 0.0, 0.0),
                100.0);
        // Set up the ambient light
        Color3f ambientColor = new Color3f(0.3f, 0.3f, 0.3f);
        AmbientLight ambientLightNode = new AmbientLight(ambientColor);
        ambientLightNode.setInfluencingBounds(bounds);
View Full Code Here

Examples of javax.vecmath.Point3d

   
    // scale the shape to have a reasonable size
    // and translate it to the origin
    Bounds bounds = transformGroup.getBounds();
    if (bounds instanceof BoundingSphere) {
      Point3d center = new Point3d();
      ((BoundingSphere)bounds).getCenter(center);
      Transform3D tr = new Transform3D();
      tr.setScale(10.0/((BoundingSphere)bounds).getRadius());
      Transform3D tr2 = new Transform3D();
      center.negate();
      tr2.setTranslation(new Vector3f(center));
      tr.mul(tr2);
      transformGroup.setTransform(tr);
    }
View Full Code Here

Examples of javax.vecmath.Point3d

      float normal[] = new float[coord.length];

        Vector3d v1 = new Vector3d();
        Vector3d v2 = new Vector3d();
        Vector3d faceNormal = new Vector3d();
        Point3d a = new Point3d();
        Point3d b = new Point3d();
        Point3d c = new Point3d();


        // step through all the faces
        for (int i=0; i<idx.length; i+=3) {

          int ja = idx[i] * 3;
            a.set(coord[ja],coord[ja+1],coord[ja+2]);
            int jb = idx[i+1] * 3;
            b.set(coord[jb],coord[jb+1],coord[jb+2]);
            int jc = idx[i+2] * 3;
            c.set(coord[jc],coord[jc+1],coord[jc+2]);

            v1.sub(b, a);
            v2.sub(c, a);
            faceNormal.cross(v1, v2);
            if (faceNormal.length()==0) continue;
View Full Code Here

Examples of javax.vecmath.Point3d

    // Create a universe bound to no canvas 3D
    ViewingPlatform viewingPlatform = new ViewingPlatform();
    // Add an interpolator to view transform to get smooth transition
    TransformGroup viewPlatformTransform = viewingPlatform.getViewPlatformTransform();
    CameraInterpolator cameraInterpolator = new CameraInterpolator(viewPlatformTransform);
    cameraInterpolator.setSchedulingBounds(new BoundingSphere(new Point3d(), 1E7));
    viewPlatformTransform.addChild(cameraInterpolator);
    viewPlatformTransform.setCapability(TransformGroup.ALLOW_CHILDREN_READ);
   
    Viewer viewer = new Viewer(new Canvas3D [0]);
    SimpleUniverse universe = new SimpleUniverse(viewingPlatform, viewer);
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.