Examples of Transform3D


Examples of com.xith3d.scenegraph.Transform3D

  }
 

  protected void createPeer(Object owner){
     
    transform=new Transform3D();
    tempTransform=new Transform3D();

    internalMakePeer(owner);
   
    peerWindow=canvasPeer.getWindow();
    if (peerWindow!=null) {
View Full Code Here

Examples of com.xith3d.scenegraph.Transform3D

      protected Transform3D transform;
      protected Transform3D tempTransform;

        public ViewTransformator() {
            super();
          transform = new Transform3D();
          tempTransform = new Transform3D();
        updateZoomMatrix();
        updateTranslateMatrix();
        applyTransform();
        }
View Full Code Here

Examples of com.xith3d.scenegraph.Transform3D

        break;
    }

    // Composed transform
    if ((transformRoot==this) && (transformChildren.size()!=0)){
      Transform3D composedTrans = new Transform3D();
     
      for(int i=transformChildren.size()-1; i>=0; i--){
        ((TransformData)transformChildren.get(i)).updateTransform();
        composedTrans.mul (((TransformDataXith3d)transformChildren.get(i)).getTransform());
      }
      composedTrans.mul(trans);
      group.setTransform(composedTrans);

     
      // Single transform
    }else{
View Full Code Here

Examples of com.xith3d.scenegraph.Transform3D

   /* (non-Javadoc)
   * @see jsynoptic3d.data.TransformData#init(int)
   */
  protected void init(int preferredKind, boolean fromNode){
    if(fromNode){
      Transform3D t = group.getTransform();
      if(t!=null){
        trans.set(t);
      }
      else{
        trans.setIdentity();
View Full Code Here

Examples of com.xith3d.scenegraph.Transform3D

    }
  }

  public Object clone() throws CloneNotSupportedException{
    TransformDataXith3d res=(TransformDataXith3d)super.clone();
    res.trans=new Transform3D();
    res.v3=new Vector3f();
    res.m3=new Matrix3f();
    res.m4=new Matrix4f();
    res.q=new Quat4f();   
    return res;
View Full Code Here

Examples of javax.media.j3d.Transform3D

  private Transform3D getModelRotationTransform() {
    float [][] modelRotation = this.controller.getModelRotation();
    Matrix3f modelRotationMatrix = new Matrix3f(modelRotation [0][0], modelRotation [0][1], modelRotation [0][2],
        modelRotation [1][0], modelRotation [1][1], modelRotation [1][2],
        modelRotation [2][0], modelRotation [2][1], modelRotation [2][2]);
    Transform3D transform = new Transform3D();
    transform.setRotation(modelRotationMatrix);
    return transform;
  }
View Full Code Here

Examples of javax.media.j3d.Transform3D

    frame.getContentPane().add("Center", canvas);
   
    peerComponent=frame;
    peerWindow=frame; 

    transform=new Transform3D();
    // avoids cumulative rounding errors
    // This should avoid "non-congruent transform above view transform" exception
    // Warning: In some cases, this exception still appears. This is a known J3D bug, that
    // should hopefully be corrected in J3D v1.4
    transform.setAutoNormalize(true);
    tempTransform=new Transform3D();
   
    viewingPlatform = scene.getUniverse().getViewingPlatform();
   
    viewer = viewingPlatform.getViewers()[0];
    view = viewer.getView();
View Full Code Here

Examples of javax.media.j3d.Transform3D

        // Create the TransformGroup node and initialize it to the
        // identity. Enable the TRANSFORM_WRITE capability so that
        // our behavior code can modify it at run time. Add it to
        // the root of the subgraph.
        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);
View Full Code Here

Examples of javax.media.j3d.Transform3D

    // TODO get platform and view according to persitent info and plugin support
    public ViewTransform(ViewingPlatform viewingPlatform) {
        _viewingMode = ROTATION_MODE;
        _viewingPlatform = viewingPlatform;
        _transform = new Transform3D();
        // avoids cumulative rounding errors
        // This should avoid "non-congruent transform above view transform"
        // exception
        _transform.setAutoNormalize(true);
        _tempTransform = new Transform3D();
        _zoom = new Matrix4f();
        _zoom.setIdentity();
        _rot = new Matrix4f();
        _rot.setIdentity();
        _trans = new Matrix4f();
View Full Code Here

Examples of javax.media.j3d.Transform3D

        res._drotX=new Matrix4f(_drotX);
        res._drotY=new Matrix4f(_drotY);
        res._trans=new Matrix4f(_trans);
        res._vtrans=new Vector3f(_vtrans);

        res._transform = new Transform3D();
        res._transform.setAutoNormalize(true);
        res._tempTransform = new Transform3D();
       
        res._viewingPlatform=null;

        res._zoomAccumulator=null;
       
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.