From 46239636fa025c6bc10b6e0b3ee0f68203622604 Mon Sep 17 00:00:00 2001
From: Thomas Oster <thomas.oster@rwth-aachen.de>
Date: Tue, 18 Sep 2012 19:28:50 +0200
Subject: [PATCH] float fix

---
 src/com/t_oster/liblasercut/drivers/LaosCutter.java | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/com/t_oster/liblasercut/drivers/LaosCutter.java b/src/com/t_oster/liblasercut/drivers/LaosCutter.java
index e98b5b8..f73aa5a 100644
--- a/src/com/t_oster/liblasercut/drivers/LaosCutter.java
+++ b/src/com/t_oster/liblasercut/drivers/LaosCutter.java
@@ -322,16 +322,16 @@ public class LaosCutter extends LaserCutter
     return result.toByteArray();
   }
 
-  private void move(PrintStream out, int x, int y, int resolution)
+  private void move(PrintStream out, float x, float y, int resolution)
   {
-    out.printf("0 %d %d\n", px2steps(isFlipXaxis() ? Util.mm2px(bedWidth, resolution) - x : x, resolution), px2steps(isFlipYaxis() ? Util.mm2px(bedHeight, resolution) - y : y, resolution));
+    out.printf("0 %f %f\n", px2steps(isFlipXaxis() ? Util.mm2px(bedWidth, resolution) - x : x, resolution), px2steps(isFlipYaxis() ? Util.mm2px(bedHeight, resolution) - y : y, resolution));
   }
   private float currentPower = -1;
   private float currentSpeed = -1;
   private float currentFocus = 0;
   private float currentFrequency = -1;
 
-  private void line(PrintStream out, int x, int y, float power, float speed, float frequency, int resolution)
+  private void line(PrintStream out, float x, float y, float power, float speed, float frequency, int resolution)
   {
     if (currentPower != power)
     {
-- 
GitLab