LDraw.org Discussion Forums
Rectifier version 1.9 - Printable Version

+- LDraw.org Discussion Forums (https://forums.ldraw.org)
+-- Forum: LDraw Programs (https://forums.ldraw.org/forum-7.html)
+--- Forum: Parts Author Tools (https://forums.ldraw.org/forum-24.html)
+--- Thread: Rectifier version 1.9 (/thread-7221.html)



Rectifier version 1.9 - Philippe Hurbain - 2012-12-13

When converting quads + lines into rect primitives, Rectifier sometimes provided values near but not equal to 1. I delved into my code and soon found a bug causing this behaviour... then found an even better method that provides tidier and more compact LDraw code.

Get new version 1.9.

Here is a sample output with Rectifier 1.8:
Code:
1 16 0 0 0 0 0 10 -1.73648 0.9848078 0 -9.84808 -1 0 rect.dat
1 16 30 -0.5 0 0 0 10 0.5 20 0 -10 1 0 rect.dat
1 16 -30 -0.555555 0 0 0 10 0.555555 0.9984604 0 -10 0.9999999 0 rect.dat
1 16 -60 -0.555555 1 0 0.005546911 10 0.555555 0.9984604 0 -10 0.9999999 -1 rect.dat
1 16 -90 -2.055555 1 0 -0.1427451 10 0.555555 0.9984604 1.5 -10 0.9999999 -1 rect.dat
1 16 -111.2485 -0.555555 -44.99815 3.827 -0.01610229 9.6215 0.555555 0.9985745 0 -9.2388 0.9999999 2.90295 rect.dat
And the output obtained with Rectifier 1.9:
Code:
1 16 0 0 0 0 0 10 -1.73648 1 0 -9.84808 0 0 rect.dat
1 16 30 -0.5 0 0 0 10 0.5 1 0 -10 0 0 rect.dat
1 16 -30 -0.555555 0 0 0 10 0.555555 1 0 -10 0 0 rect.dat
1 16 -60 -0.555555 1 0 0 10 0.555555 1 0 -10 0 -1 rect.dat
1 16 -90 -2.055555 1 0 0 10 0.555555 1 1.5 -10 0 -1 rect.dat
1 16 -111.2485 -0.555555 -44.99815 3.827 0 9.6215 0.555555 1 0 -9.2388 0 2.90295 rect.dat
In this example, LDraw code was shrunk at 37% with 1.8, it's now only 29%.
Note that there was nothing wrong with 1.8 result, as inlining back both versions gives exactly the same lines and quads.


Re: Rectifier version 1.9 - Michael Heidemann - 2012-12-13

I will combine this into the next release of LETGui, that should be ready within the next four weeks.