Examples of GetPaperHeight()


Examples of Makelangelo.MachineConfiguration.GetPaperHeight()

    int w = img.getWidth();
    int h = img.getHeight();
   
    // cap the max_w and max_h so that enormous drawbot images don't break the software.
    double paper_w= mc.GetPaperWidth();
    double paper_h= mc.GetPaperHeight();
    // TODO make this number a variable that can be tweaked
    int max_w=maxWidth;
    int max_h=maxHeight;
    if(paper_w>paper_h) {
      max_h *= paper_h/paper_w;
View Full Code Here

Examples of Makelangelo.MachineConfiguration.GetPaperHeight()

   * setup transform when there is no image to convert from.  Essentially a 1:1 transform.
   */
  protected void SetupTransform() {
    MachineConfiguration mc = MachineConfiguration.getSingleton();
    // TODO I don't remember why these * 20 are needed here.  Find out and comment the code.
    SetupTransform( (int)mc.GetPaperWidth()*20, (int)mc.GetPaperHeight()*20 );
  }
 
  protected void SetupTransform(int width,int height) {
    image_height = height;
    image_width = width;
View Full Code Here

Examples of Makelangelo.MachineConfiguration.GetPaperHeight()

    if(image_width>mc.GetPaperWidth()) {
      float resize = (float)mc.GetPaperWidth()/(float)image_width;
      scale *= resize;
      new_height *= resize;
    }
    if(new_height>mc.GetPaperHeight()) {
      float resize = (float)mc.GetPaperHeight()/(float)new_height;
      scale *= resize;
      new_width *= resize;
    }
    scale *= mc.paper_margin;
View Full Code Here

Examples of Makelangelo.MachineConfiguration.GetPaperHeight()

      float resize = (float)mc.GetPaperWidth()/(float)image_width;
      scale *= resize;
      new_height *= resize;
    }
    if(new_height>mc.GetPaperHeight()) {
      float resize = (float)mc.GetPaperHeight()/(float)new_height;
      scale *= resize;
      new_width *= resize;
    }
    scale *= mc.paper_margin;
    new_width *= mc.paper_margin;
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.