Open iceblu3710 opened 6 years ago
The polygon libraries only support integer coordinates. See mesh.js for the conversion factors.
Ah I see a 2e-8 scale factor from mmtoclipper being applied.
What is the common entry point to the gcode process? I would like my path mapper function to sort the camPaths just before handing the camPaths to the cam modules as there are several different versions.
I have a very simple 10mm square. When inspecting the path in the workspace it makes perfect since, its closed off and everything is happy. When I interrupt the gcode processor for the millng operations just before camPaths is turned into gcode everything is really off. The camPath path values are way to large, even if its an implied precision its out by 2x. What is really wierd is that the gcode is 10mm like it should be....
I am trying to write in a gcode optimizer as well as UNoptimizer. My CNC requires max Y plunge points only as its at an 80deg angle and a through cut piece would fall into the bit unless its entry/exit is max Y somewhere. I have a routine to find maxY and rotate the paths so the start point is that location but I am very unsure of where to actually put this pre-processor.
Path from the workspace:
camPaths while at: https://github.com/LaserWeb/LaserWeb4/blob/22e0f7e3cf4d0ce36741426920e37a5e120247e2/src/lib/cam-gcode-mill.js#L256