It is currently Sat Aug 22, 2020 4:29 am


All times are UTC




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: [Solved] surfaceExtractors and pointer
PostPosted: Thu May 09, 2013 7:17 am 

Joined: Sun Jan 08, 2012 10:00 am
Posts: 31
Location: Germany
if i use a pointer to a SimpleVolume it compiles and works for example then i have to write
maxx=volpointer->getWidth();
if i then use a pointer to a SurfaceExtractor from the Volumepointer(the same with Normals or Marchingcubes)
Code:
PolyVox::MarchingCubesSurfaceExtractor <PolyVox::SimpleVolume<MDVoxel>>*  surfaceExtractorMCPointer;
PolyVox::MarchingCubesSurfaceExtractor <PolyVox::SimpleVolume<MDVoxel> >  surfaceExtractorMC(volpointer, volpointer->getEnclosingRegion(), &polyvoxmesh);
surfaceExtractorMCPointer=&surfaceExtractorMC;
surfaceExtractorMCPointer->execute();

the program also compiles but the program hangs up, please whats wrong cause it compiles it seems to be correct c++


Last edited by zprg on Fri May 10, 2013 4:01 pm, edited 1 time in total.

Top
Offline Profile  
Reply with quote  
 Post subject: Re: surfaceExtractors and pointer
PostPosted: Fri May 10, 2013 7:52 am 
Developer
User avatar

Joined: Sun May 04, 2008 6:35 pm
Posts: 1827
Are you sure it it the use of a pointer which is the problem here? That seems unlikely. So just to be clear, you say that this code will work:

Code:
surfaceExtractorMC.execute();


But that this code will crash:

Code:
surfaceExtractorMCPointer=&surfaceExtractorMC;
surfaceExtractorMCPointer->execute();


Seems very strange... If that's not what you mean, then can you give an example of working code compared to non-working code?


Top
Offline Profile  
Reply with quote  
 Post subject: Re: [Solved] surfaceExtractors and pointer
PostPosted: Fri May 10, 2013 4:23 pm 

Joined: Sun Jan 08, 2012 10:00 am
Posts: 31
Location: Germany
thank you, ah i was searching in the wrong edge, yes now i see the problem is somewhere else.


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

All times are UTC


Who is online

Users browsing this forum: No registered users and 3 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