Hi Ola,

On 27 August 2012 15:23, Ola Nilsson <o...@weatherone.tv> wrote:
> Hm, there is probably something I don't see. I am new to the code...
>
> I assumed that a TerrainTile cannot be _completely_ deleted in the
> Terrain::update call, because if it were it _must_ have passed through
> Terrain::unregisterTile and then it wouldn't be in the update set to begin
> with.

unregisterTile only gets called in the TerrainTile destructor after
it's ref count has gone to zero.  It'd be safe if unregisterTile was
called prior to the TerrailTile object's ref count goes to zero.

> Therefore it is still safe to investigate the raw pointers in the
> _updateTerrainTileSet in Terrain::update.
>
> Do you agree on the assumption? If not can you exemplify when it doesn't
> hold?

Nope it's not safe as explained above.

Robert.
_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to