RE: LDraw Torus Generator
2017-06-08, 4:42 (This post was last modified: 2017-06-08, 8:33 by Kevin.)
2017-06-08, 4:42 (This post was last modified: 2017-06-08, 8:33 by Kevin.)
(2017-06-07, 21:18)Magnus Forsberg Wrote: OK, we need this, but then the header needs more tweaking.
The naming of torus primitives are tricky. A correct name would be: 48/tm48q?????.dat
The parttype should be: Unofficial_48_Primitive.
It should have a BFC statement: 0 BFC CERTIFY CCW
A scalable primitive must have four decimals on every x/y/z value.
OK, maybe I'm nitpicking, but these changes would make it usable.
Thanks for the additional feedback. I have made the requested changes:
1) If the sections per circle is 48 or greater, "48\" is prepended to the name, and "_48" is inserted into the parttype.
2) Added support for "unit" in the file name when the minor radius = 1
3) I corrected and verified the CCW winding for all quadrilaterals and added the BFC statement.
4) I have expanded the precision to 4 decimal places but allow truncation of trailing zeros for quads and edges.
Right now it only generates q-type tori. Would it be useful to add i-, o-, and r- types as well?
Kevin