# Re: [rp-ml] CSG correctness. (LONG!)

Date: Sat Dec 09 2006 - 22:35:09 EET

Quoting steve <sjbaker1@airmail.net>:

>
>> A closely-related, and maybe even better, alternative is simply to
>> substitute z = 3.85 (o.w.e.) into the entire CSG expression when
>> you're making the layer at 3.85 mm high. Then the model becomes an
>> even simpler 2D CSG one, whereupon you do a quad-tree division in
>> that plane, and have your RP machine zap the resulting bunch of
>> rectangles.
>
> Hmmm. I'm not quite sure how you'd do that directly - I need to think

It's quite easy in fact. The CSG expression stays identical. The
neatest and most versatile way to describe the leaves is to have them
as implicit inequalities like

ax + by +cz + d <= 0 (plane)

or

ax^3yz^4 + bx^2y + czy <= 0 (funny squiggly shape)

then you just put your z = 3.85 in them and they become 2D leaves of
the same CSG tree with just x and y as variables.

The funny squiggly shapes include all the usual suspects like the
torus, cone etc, and also complicated blendy patchy things that you can
make using Liming blends or metaball techniques. It's a much richer
set than you can do with mere NURBS...

Yours