Examples of globalToLocal()


Examples of ca.nengo.ui.lib.world.WorldObject.globalToLocal()

    // Now loop through the stack of nodes and transform the point
    // into the proper network's coordinate system
    Point2D newPosition = globalPosition;
    while (!objStack.empty()) {
      obj = objStack.pop();
      newPosition = obj.globalToLocal(newPosition);
      if (obj instanceof NodeViewer)
        newPosition = ((NodeViewer)obj).localToView(newPosition);
      else
        newPosition = ((NodeContainer)obj).localToView(newPosition);
    }
View Full Code Here

Examples of ca.nengo.ui.lib.world.WorldObject.globalToLocal()

    // Loop through selected objects, compensate for camera panning
    // so that objects will remain stationary relative to cursor
    Iterator<WorldObject> selectionEn = selectionHandler.getSelection().iterator();
    while (selectionEn.hasNext()) {
      WorldObject node = selectionEn.next();
      node.localToParent(node.globalToLocal(delta));
      node.dragOffset(delta.getWidth(), delta.getHeight());
    }
  }

  public void setInverted(boolean isInverted) {
View Full Code Here

Examples of ca.nengo.ui.lib.world.WorldObject.globalToLocal()

          if (droppable.acceptTarget(worldLayer)) {
            target = worldLayer;
          }
        }
        if (target != null) {
          Point2D position = target.globalToLocal(node.localToGlobal(new Point2D.Double(
              0, 0)));

          node.setOffset(position);
          target.addChild(node);
          droppable.justDropped();
View Full Code Here

Examples of ca.nengo.ui.lib.world.piccolo.WorldObjectImpl.globalToLocal()

        WorldObjectImpl node = selectionEn.next();
        if (!node.isAnimating()) {
          PDimension gDist = new PDimension();
          gDist.setSize(d);

          node.localToParent(node.globalToLocal(gDist));

          node.dragOffset(gDist.getWidth(), gDist.getHeight());
        }
      }
    }
View Full Code Here

Examples of org.mt4j.components.visibleComponents.shapes.AbstractShape.globalToLocal()

        windowBackGround.scaleGlobal(se.getScaleFactorX(), se.getScaleFactorY(), se.getScaleFactorZ(), se.getScalingPoint());
       
        //Scale vertices of the window
        AbstractShape target = (AbstractShape)ge.getTargetComponent();
        Vertex[] verts = target.getGeometryInfo().getVertices();
        Vector3D newScalingPoint = target.globalToLocal(se.getScalingPoint());
        Matrix m = Matrix.getScalingMatrix(newScalingPoint, se.getScaleFactorX(), se.getScaleFactorY(), se.getScaleFactorZ());
        Vertex.transFormArray(m, verts);
        target.setVertices(verts);

        //Scale vertices of the clip shape
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.