This does work I use this all the time, its basic debugging technique to me
Gordon Product Manager 3d __________________________________________________________ Gordon Tomlinson Email : gtomlinson @ overwatch.textron.com __________________________________________________________ -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Chris Denham Sent: Wednesday, August 19, 2009 12:13 PM To: [email protected] Subject: Re: [osg-users] Reference count catcher? Of course you spotted the deliberate mistake... should be "this==0xblahblah" C. ----- Original Message ----- From: "Chris Denham" <[email protected]> To: <[email protected]> Cc: <[email protected]> Sent: Wednesday, August 19, 2009 5:10 PM Subject: Re: [osg-users] Reference count catcher? > Hi Ufuk, > You don't need to know the address of your geometry at compile time. > Put a break point on the place where you create the geometry. > Run to that point and make a note of its address (or copy it to > clipboard). > Set a break point in Referenced::ref and right click on the red breakpoint > blob. > Choose "conditional break point" and set it to 'this=0xblahblah' > (substituting blahblah with your object address). > Run again, and then it should break each time ref is called for your > geometry. > Beware that it may be called a few more times than you might expect as > pushing to arrays of ref counted objects may create temporary ref ptr > objects as the array is reallocated. > It does work.. just tried it in VS2005. > Cheers. > Chris. > >> Date: Wed, 19 Aug 2009 16:36:58 +0300 >> From: Ufuk <[email protected]> >> Subject: Re: [osg-users] Reference count catcher? >> To: OpenSceneGraph Users <[email protected]> >> Message-ID: >> <[email protected]> >> Content-Type: text/plain; charset="iso-8859-1" >> >> Hi Gordon, >> i cant place a break point into osg::Referenced class. if i put i get >> every >> classes which are referenced. >> and since the compile time, i can not know the address of my geometry i >> cant >> add such an if. >> anyway it is the whole rebuild of osg library. >> >> if i venture this, i do the method that ismail has told before... it >> seems a >> better idea.. >> > _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.or g _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

