It is currently Sat Aug 22, 2020 1:34 pm


All times are UTC




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Tutorial should have a notice
PostPosted: Sun Nov 25, 2012 6:29 pm 

Joined: Fri Nov 23, 2012 7:20 pm
Posts: 3
The tutorial on your site should at least have a notice that the code's out of date.

The constructor syntax for CubicSurfaceExtractorWithNormals doesn't use the new style of
Code:
CubicSurfaceExtractorWithNormals<SimpleVolume<MaterialDensityPair44>>
            surfaceExtractor(...)

Also this portion of the sphere creation code doesn't work:
Code:
uint8_t uDensity = MaterialDensityPair44::getMaxDensity();

                                        //Get the old voxel
                                        MaterialDensityPair44 voxel = volData.getVoxelAt(x,y,z);

                                        //Modify the density
                                        voxel.setDensity(uDensity);

                                        //Wrte the voxel value into the volume
                                        volData.setVoxelAt(x, y, z, voxel);


It instead needs to be changed to:
Code:
volData->setVoxelAt(x, y, z, MaterialDensityPair44(1,MaterialDensityPair44::getMaxDensity()));

I have lost nearly 2 days of my time sorting this out : \


Top
Offline Profile  
Reply with quote  
 Post subject: Re: Tutorial should have a notice
PostPosted: Sun Nov 25, 2012 6:54 pm 
Developer
User avatar

Joined: Sun May 11, 2008 4:29 pm
Posts: 198
Location: UK
I just replied to you on reddit also. The links from the documentation page were just outdated and pointing at the old version of the docs. I've just corrected them to point to the 0.2 version. The tutorial there should definitely work with the released version 0.2. If that doesn't work then it's a bug so please let us know.

_________________
Matt Williams
Linux/CMake guy


Top
Offline Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
Theme created StylerBB.net