Examples of rotate()


Examples of com.cburch.logisim.data.Location.rotate()

      Location loc = port.getLocation();
      if (anchor != null) {
        loc = loc.translate(-anchor.getX(), -anchor.getY());
      }
      if (facing != defaultFacing) {
        loc = loc.rotate(defaultFacing, facing, 0, 0);
      }
      ret.put(loc, port.getPin());
    }
    return ret;
  }
View Full Code Here

Examples of com.cloudera.flume.agent.durability.NaiveFileWALDeco.rotate()

    wal.open();
    for (int i = 0; i < count; i++) {
      Event e = new EventImpl(("test message " + i).getBytes());
      wal.append(e);
      if (i % 5 == 4) {
        wal.rotate();
      }
    }

    CounterSink ctr = (CounterSink) ReportManager.get().getReportable(rpt);
    LOG.info("Last batch should be missing. " + count + " > " + ctr.getCount()
View Full Code Here

Examples of com.cloudera.flume.handlers.rolling.RollSink.rotate()

    LOG.info(tag2);
    snk.append(ackedmem.next()); // ack beg
    snk.append(ackedmem.next()); // data
    snk.append(ackedmem.next()); // ack end
    Clock.sleep(10); // have to make sure it is not in the same millisecond
    roll.rotate();
    // two acks pending.
    assertEquals(2, node.getAckChecker().getPendingAckTags().size());
    node.getAckChecker().checkAcks();
    // no more acks pending.
    assertEquals(0, node.getAckChecker().getPendingAckTags().size());
View Full Code Here

Examples of com.flansmod.common.vector.Matrix4f.rotate()

         
          Matrix4f mat = new Matrix4f();
          mat.m00 = currentWheelPos.x;
          mat.m10 = currentWheelPos.y;
          mat.m20 = currentWheelPos.z;
          mat.rotate(dAngle * type.wheelSpringStrength, rotateAround);
         
          axes.rotateGlobal(-dAngle * type.wheelSpringStrength, rotateAround);
                   
          Vector3f newWheelPos = new Vector3f(mat.m00, mat.m10, mat.m20);
          newWheelPos.normalise().scale(newLength);
View Full Code Here

Examples of com.google.code.appengine.awt.geom.AffineTransform.rotate()

            double centerX = anchor.getX() + anchor.getWidth()/2;
            double centerY = anchor.getY() + anchor.getHeight()/2;

            AffineTransform trans = new AffineTransform();
            trans.translate(centerX, centerY);
            trans.rotate(Math.toRadians(angle));
            trans.translate(-centerX, -centerY);

            Rectangle2D rect = trans.createTransformedShape(anchor).getBounds2D();
            if((anchor.getWidth() < anchor.getHeight() && rect.getWidth() > rect.getHeight()) ||
                (anchor.getWidth() > anchor.getHeight() && rect.getWidth() < rect.getHeight())    ){
View Full Code Here

Examples of com.google.gwt.canvas.dom.client.Context2d.rotate()

        context.setLineWidth(0.01);
        for (Body body = scene.getWorld().getBodyList(); body != null; body = body.getNext()) {
            Vec2 center = body.getPosition();
            context.save();
            context.translate(center.x, center.y);
            context.rotate(body.getAngle());
            for (Fixture fixture = body.getFixtureList(); fixture != null; fixture = fixture.getNext()) {
                Shape shape = fixture.getShape();
                if (shape.getType() == ShapeType.CIRCLE) {
                    CircleShape circle = (CircleShape)shape;
                    context.beginPath();
View Full Code Here

Examples of com.googlecode.jumpnevolve.math.Vector.rotate()

    // ref: Richtung nach der das Rechteck ausgerichtet wird
    Vector pos = this.getPosition().sub(this.getParentPosition()), ref = this
        .getReferenceVector(), re = Vector.ZERO;

    // Vektor entsprechend der Ausrichtung berechnen
    re = pos.rotate(-ref.clockWiseAng());

    // Dimensionsangaben sind immer positiv
    // Jedes Rechteck muss über Breite und Höhe verfügen
    re = re.modifyX(Math.max(Math.abs(re.x), 1));
    re = re.modifyY(Math.max(Math.abs(re.y), 1));
View Full Code Here

Examples of com.itstherules.image.AWTImage.rotate()

  @Override
  public void update(Map<String, Object> parameters, HttpServletResponse response) throws IOException {
    String directory = (String) parameters.get("directory");
    String imageName = (String) parameters.get("image");
    IImage image = new AWTImage(PathResolver.resolve("photos/"+directory+"/"+imageName, PhotosController.class));
    image.rotate(getIntParameter(parameters.get("rotation")));
    image.scale(getIntParameter(parameters.get("width")), getIntParameter(parameters.get("height")), true, true);
    image.save();
    try {
      IImage thumbnailImage = new AWTImage(PathResolver.resolve("photos/"+directory+"/thumbnails/"+imageName, PhotosController.class));
        thumbnailImage.rotate(getIntParameter(parameters.get("rotation")));
View Full Code Here

Examples of com.itstherules.image.IImage.rotate()

  @Override
  public void update(Map<String, Object> parameters, HttpServletResponse response) throws IOException {
    String directory = (String) parameters.get("directory");
    String imageName = (String) parameters.get("image");
    IImage image = new AWTImage(PathResolver.resolve("photos/"+directory+"/"+imageName, PhotosController.class));
    image.rotate(getIntParameter(parameters.get("rotation")));
    image.scale(getIntParameter(parameters.get("width")), getIntParameter(parameters.get("height")), true, true);
    image.save();
    try {
      IImage thumbnailImage = new AWTImage(PathResolver.resolve("photos/"+directory+"/thumbnails/"+imageName, PhotosController.class));
        thumbnailImage.rotate(getIntParameter(parameters.get("rotation")));
View Full Code Here

Examples of com.jcloisterzone.ui.ImmutablePoint.rotate()

        for (FeatureDescriptor fd : lookups) {
            point = points.get(fd);
            if (point != null) break;
        }
        if (point == null) return null;
        return point.rotate(tile.getRotation());
    }
}
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.