Volumes Of Fun

paging smooth blocks
Page 1 of 1

Author:  Alex [ Mon Aug 13, 2012 6:27 pm ]
Post subject:  paging smooth blocks


To improve performance when editing a volume, i have created many volumes instead of one.
I want my final object to be smooth so i use the SurfaceExtractor + MeshDecimator.

The problem : SurfaceExtractor rounds the borders of each volume :(

screeshoot :

I use SimpleVolume, and when i was searching for my problem, i saw the mention of pagination with LargeVolume. Using it instead of tridimentional array of SimpleVolume will resolve the problem ?
(by the way, is there some example of LargeVolume pagination ?).

Or maybe the SurfaceExtractor must be change to something I don't know yet ?

Thanks for helping me :)

Author:  Freakazo [ Tue Aug 14, 2012 3:25 am ]
Post subject:  Re: paging smooth blocks

Your best option is to use largevolume, but the problem you're experiencing is unrelated.

As the extractor is iterating over all the voxels to extract it is looking at the neighbouring voxels to calculate where it should place vertices etc. Now what happens at the border of the volume the extractor will try to look to its neighbours, but in this case its neighbours are outside of the volume you specified so the extractor assumes it be empty.

This means that you have to extract a region smaller than the size of the region you created so that the extractor knows what density values the neighbours for the voxels on the edge of your extracted region is. With simpleVolume this means that each volumes size will have to be bigger and overlap with over volumes' regions in your array. That method will cause there to be some duplicated data, however with LargeVolume the same data will be accessible to the extractor.

Author:  David Williams [ Tue Aug 14, 2012 8:28 am ]
Post subject:  Re: paging smooth blocks

I just updated our only FAQ entry regarding this: http://www.gitorious.org/polyvox/polyvo ... on/faq.txt

Note that I didn't expect you to find that link as it's not published yet... it's just something I'm working on for the next release.

Freakazo is correct about the cause, although I wouldn't recommend overlapping volumes as a solution. Check out LargeVolume if you want to go big, though even SimpleVolume should go up to 512^3 for testing purposes and you may find it's faster.

Author:  Alex [ Wed Aug 15, 2012 8:15 pm ]
Post subject:  Re: paging smooth blocks

I just changed my code to use only one volume.
The result is clearly better !

Thanks !

Page 1 of 1 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group