David Williams wrote:
Not really, I think use of templates is generally very beneficial.
I like templates too, but because they're absolutely not portable between languages they are pain in the ass when it's the only way to use functionality.
David Williams wrote:
Would a simplified C++ wrapper be sufficient instead?
For me? sure! For most of people here too, so it might be the way.
David Williams wrote:
I think a simpified wrapper will only be useful if it exposes a reduced feature set. Perhaps we choose one volume type (SimpleVolume) and one voxel type (MaterialDensityPair88) and just expose this as a class called 'Volume'. Then simple 'extractSmoothSurface' and 'extractCubicSurface' functions to avoid messing around with the surface extractor classes.
Actually, I've been thinking about another way. Abandon the need of templates by making additional untyped methods/functions + some c-style callbacks. It won't look good, nor it won't be easy to use, but it would let to be flexible, and portable in the same time.
About method you proposed, I would have to use current API anyway, but for some people it might help.
David Williams wrote:
I am quite in favour of this, but I don't want to write the SWIG part. If someone else can volenteer then great, but even without that it would be useful for less experienced C++ programmers. I will add it to the todo list...
I don't really understand SWIG usage, maybe because i had no time to read complete manual. I just made it work for me, and i'm trying to keep away from it, so i cannot offer my help here

David Williams wrote:
1) Make a new PolyVoxBasic namespace for the simplified interface. Does this mean the existing classes should be moved to PolyVoxAdvanced, or just stay in PolyVox? The Region class will be needed by both simplified and normal code so where should this go? Should a user of PolyVoxBasic also have to include the normal/advanced namespace to access Region?
Definitely alternative ways shouldn't be mixed, so PolyVoxBasic would better for me. IMO, current namespace shouldn't be touched. I see nothing wrong in having PolyVox and PolyVoxBasic, which keeps using PolyVox.
And i think this solution would be best of three mentioned because of 2) just no, lol

3) i think it would add some mess.