AndiNo wrote:
Hi!
After some research I concluded that PolyVox might be just the thing I'm looking for. I want to create a world similar to Minecraft in Ogre3D. I already looked into the Thermite3D source code. Now I have two questions:
Hi, and welcome to the Thermite3D community. I've been following the recent thread on the Ogre forums so I'm glad you decided to come by and give PolyVox a go
AndiNo wrote:
1. Do you think it's a good idea to use PolyVox for a Minecraft-like world where you can "edit" the world? And what would be the expected FPS in Ogre when having a 256^3 voxel world for example? (maybe you can post your experiences and system specs for comparison)
Yes, I think that will work well. If you haven't already tried it, you should have a play with
the Thermite3D Tech Demo. It's the demo from the YouTube video on the front page and is a couple of years old now, but that castle is in a 256^3 volume (though it only occupies the lower half). As you can see, it destroys hundreds of voxels at a time.
This demo was actually using the Marching Cubes surface extractor, where as I imagine you'll be more interested in the new 'cubic' surface extractor. This has not been optimised at all but still runs faster than the Marching Cubes version because it is a simpler algorithm.
AndiNo wrote:
2. From what I have seen in the Thermite code I'll have to use the code from the SurfacePatchRenderable::buildRenderOperationFrom function to get the PolyVox volume to render. Is this the best/fastest approach or are there any better ideas?
That code is in need of a clean up and is more complex than it needs to be. It handles things like duplicating trianges to blend between material - this problem simply doesn't exist when working with the cubic surface extractor. Your best bet is to make use of the Ogre 'ManualObject' class, and then maybe HardwareBuffers at a later date.
Also, have a look at
this tutorial and the Basic Example which comes with PolyVox.
Let me know if you have any more questions!