Adjust rendering to center on Z
- Issue MatterHackers/MCCentral#2115 Layer lines render half a nozzle higher than expected
This commit is contained in:
parent
0e26d59d78
commit
5e7e8cf502
1 changed files with 4 additions and 0 deletions
|
|
@ -62,6 +62,10 @@ namespace MatterHackers.GCodeVisualizer
|
|||
double zScale = halfHeight / radius;
|
||||
double xScale = halfWidth / radius;
|
||||
|
||||
// Adjust start/end positions to be centered on Z for the given layer height
|
||||
startPos.Z -= halfHeight;
|
||||
endPos.Z -= halfHeight;
|
||||
|
||||
Vector3 scale = new Vector3(xScale, xScale, zScale);
|
||||
|
||||
for (int i = 0; i < steps; i++)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue