Hi Josh,

That's not an issue with nesting, but a naming issue: stud2.dat is a LDraw primitive (stud with middle hole) that must somehow be used instead of your file. LDraw library also include stud groups to reduce file size, they are named according this pattern: stugTXxY.dat where T is the type of stud (nothing for regular stud, 2 for stud with hole, 4 for bottom tube), X and Y the array sizes.

Only square and linear arrays are supported, eg.
stug-9x9.dat
stug2-6x1.dat
stug-1x5.dat
note that Xx1 and 1xY exist to care for stud logo orientation.

I suggest that you use this scheme to avoid confusion...

Philo


Johannes Schauer a écrit :
Hi,

Quoting Leonardo Zide (2014-09-11 03:38:40)
That's much better, the zipped file is down to 80 Kb. It may still be a
little too big to include it as data (I think the limit is either 32 or
64Kb), I'll take another look and see if I can trim it down some more.  There
were still some .0s in there, but I removed them with sed.

most space seems to be wasted by the baseplates with large amounts of studs.

To solve it, I thought of creating a file stud2.dat which includes a 2x2 array
of stud.dat, a file stud4.dat which includes a 2x2 array of stud2.dat and so on
and so forth until stud32.dat. Then it would be easy to subdivide any array of
studs so that only very few lines of code are needed.

Unfortunately it seems that LDView for example cannot handle multiple levels of
nesting like this. While it should display this for stud4.dat:

https://mister-muffin.de/p/MLV6.png

It actually shows this:

https://mister-muffin.de/p/aBPM.png

I reported this in their bugtracker https://sourceforge.net/p/ldview/bugs/6/
because apparently arbitrary nesting should be supported
http://www.ldraw.org/article/218.html#lt1

Now my question is: can leocad handle arbitrary nesting?

I attached stud1.dat, stud2.dat and stud4.dat so that you might check. I was
unable to load even stud1.dat in leocad.

cheers, josch



_______________________________________________
Leocad mailing list
[email protected]
https://list.gerf.org/listinfo/leocad


_______________________________________________
Leocad mailing list
[email protected]
https://list.gerf.org/listinfo/leocad

Reply via email to