kanzure / python-brlcad

Open-source solid modeling in python
11 stars 8 forks source link

added arbitrary boolean tree support for writing regions/combinations; #19

Closed ncsaba closed 10 years ago

ncsaba commented 10 years ago

Hi Bryan,

Another fairly big patch - but it adds quite some news:

For now only ARB8 and Combination are implemented, but that was enough for a proof of concept. The rest comes next; I'm also quite sure there bugs in there, so lots of more work is needed !

Again the biggest challenge was to figure out memory being freed by BRL-CAD for parameters given to the library functions - all that needs to be also allocated in BRL-CAD code, that's why some copying around is done.

I added also a unit test test_wdb.py, which will replace with time the one in test directory, and then I will delete that directory altogether. For now I still keep that one to quickly visually check that my changes didn't break anything which already worked (I fire up mged for that and display all.r).

Cheers, Csaba

ncsaba commented 10 years ago

I added an example (hilbert_2d/3d) which creates a hilbert curve out of a single pipe primitive.

The focus is not that much on exercising many BRL-CAD feature, but more on showing that complex things are possible with the combination of python and BRL-CAD !

Cheers, Csaba

kanzure commented 10 years ago

Thank you!