David Williams wrote:
Having your terrain as a thin shell rether than a solid object will have a negative effect, because PolyVox will generate polygons on both sides of it. I.e. there will be polygons point up from the shell to the empty space above, but there will also be polygons pointing down from the shell to the empty space below. This is necessary because PolyVox doesn't know where you are going to place the camera.
The volume class will store the data quite happily, but you will get more polygons during surface extraction.
My new ideas solve this of course.
And, with a custom Extractor, I could even generate polygons that face only a certain way etc.
I am working on an implementation of my ideas suggested above, and my Extractor is very generic, and allows callbacks and policies for every detail I can manage. Thus, one can easily choose to ignore triangles, or do any sort of custom generation without too much hassle.
David Williams wrote:
This sounds messy as you've potentially got different data in the differnt LOD levels. The Eric's TransVoxel algorithm will handle the crack which occur when one volume is simply a lower resolution version of another volume, but I think actually placing differnt data into each volume will cause problems.
The problem with his algorithm is that it seems to require to average or otherwise process the higher resolution voxels to generate the lower LOD surface. This seems wasteful; it saves space, but requires similar amount of CPU time/computational complexity. Thus for example, you would not be able to deal with an entire (actual size) planet of voxels ... that would require building up from the bottom. But fractal noise naturally builds down from the top ... that is, you get a low resolution of noise (smoothed out), and you then add its own (faded) image four times into itself at half resolution; this adds detail, but from a distance this detail is not really visible. I am trying to apply the same idea to voxel generation. I dunno if it will mess up the crack-patching algorithm; I'll get back to you
. Otherwise, there are other methods of zooming with a top-down approach I am investigating.
David Williams wrote:
Yeah, I've heard there are some performance issues here. I can't yet tell you where the problem lies (paging, compression, use of std::map, etc) as it needs some investigation. But I'm currently in the process of modifying PolyVox to allow different volume classes, and will then add a simple raw data volume which can be used for comparison.
Noise generation is the best compression
.
To support destructibility in my world, I intend to use an inverse Volume; one that would indicate where the world differs from the noise generator. Thus, my volume's getPixel would first check the inverse Volume, then if it finds nothing, it would ask the noise generator for a voxel (I am using the Simplex noise generator for 3D btw).
I am also using my own Surface Extractor for now, using the regular cell data from the Transvoxel Marching cubes.