Volumes Of Fun http://www.volumesoffun.com/phpBB3/ |
|
PolyVox in c# http://www.volumesoffun.com/phpBB3/viewtopic.php?f=14&t=349 |
Page 1 of 1 |
Author: | mathius777 [ Thu Mar 29, 2012 7:33 pm ] |
Post subject: | PolyVox in c# |
Hey everyone. I downloaded PolyVox and ran the MakeCSharpBindings.bat file and added all the .cs files to my c# project. I was trying to use the tutorial at http://www.volumesoffun.com/polyvox/doc ... rial1.html but I noticed that the .cs files that are created don't have BaseVolume, which has the getWidth() method, and so I can't get any further in the tutorial. Is there any other place this functionality exists? I really want to use PolyVox with c#. Thanks. |
Author: | xelons [ Thu Mar 29, 2012 7:51 pm ] |
Post subject: | Re: PolyVox in c# |
Hello! I think on that tutorial they use SimpleVolume, so you may be looking for something like SimpleVolume.cs |
Author: | mathius777 [ Thu Mar 29, 2012 8:09 pm ] |
Post subject: | Re: PolyVox in c# |
Hey. In the converted c# files, simplevolume.cpp became SurfaceExtractorSimpleVolumeMaterial8.cs. And this class doesn't have getwidth(). |
Author: | David Williams [ Fri Mar 30, 2012 9:43 am ] |
Post subject: | Re: PolyVox in c# |
I admit that the bindings are not in good shape, unfortunatly we don't use them ourselves and so they tend to break when we make changes to the library and don't update them. You may need some C++/SWIG knowledge to get them working. That said: mathius777 wrote: ...simplevolume.cpp became SurfaceExtractorSimpleVolumeMaterial8.cs... I don't think this is true. SimpleVolume should become SimpleVolumeMaterial8 and SimpleVolumeDensity8, as defined in SimpleVolume.i. What you have identified is actually a surface extractor which operates on a SimpleVolumeMaterial8. Leave surface extraction aside for a moment, and see if you can just get SimpleVolumeMaterial8 to work. I would expect getWidth() etc to be inherited from the base class but I haven't tested it. |
Author: | mathius777 [ Fri Mar 30, 2012 10:47 am ] |
Post subject: | Re: PolyVox in c# |
You're right I posted the wrong thing, my bad. I was using SimpleVolumeDensity8, which doesnt have getwidth. So it is basically up to me to make the bindings. I can live with that. I just wanted to make sure I wasn't missing something, thanks. |
Author: | mathius777 [ Fri Mar 30, 2012 11:46 am ] |
Post subject: | Re: PolyVox in c# |
A more important thing to ask is why SurfaceTriangle.h doesn't exist anywhere. It is used in SurfaceEdg.cpp, but this .h doesn't exist anywhere, and it's needed to compile the library. Same with SurfaceVertex.h in the same .cpp |
Author: | David Williams [ Fri Mar 30, 2012 11:59 am ] |
Post subject: | Re: PolyVox in c# |
As far as I can see, SurfaceTriangle/SurfaceEdge/SurfaceVertex are no longer part of PolyVox. The source code still exists on disk (and should be removed as it is confusing) but it is never included into the library. The files which are included into the library are controlled by the CMakeLists.txt which you can see here. Note that SurfaceMesh is still used, but the other Surface*** classes are not. Edit: I've now removed these old files from the repository, so this should prevent confusion in the future. Don't update though - Git master is rather unstable at the moment. |
Page 1 of 1 | All times are UTC |
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group http://www.phpbb.com/ |