Dear OSGers,

I'm kind of stumped and I was hoping that somebody might tell me where to
look...

I have a HUD (simple geometry underneath a Ortho projection node underneath
a Post-render camera) exactly as per the osgpick example . I pick exactly as
per osgpick, although I parse mouse button events (push, release, drag)
rather than FRAME events. I have several "windows", which consist of a
matrix transform, and various bits of geometry - rectangles, text etc. -
underneath. I have code that enables DRAG to move the window by updating the
transform. Some of the window elements occasionally are changed (e.g. text
updated etc.).

Now the problem : usually, view->computeIntersections correctly returns a
number of hits based on what is under the mouse pointed. However, if nothing
is changing in the window, then view->computeIntersections() _usually_ fails
to intersect with _any_ of the underlying geometry of that window.

I say usually because to start with, all is fine, but after a few seconds of
moving windows around, the intersection visitor no longer returns hits from
them.

If any geometry in the window changes, then view->computeIntersections will
then return valid geometry intersections for a while, until it stops
returning anything. The geometry is still there, on screen, just unpickable
with a LineSegmentIntersector.

What is particularly wierd is the fact that it works for a while and then
stops working. I have tried to work my way through the
LineSegmentIntersector, but got lost. Is there some cache of objects for
intersection that isn't being updated? All the objects have their data
variance set as DYNAMIC, so not sure it can be that. Am I missing something
akin to calling dirty() somewhere, in order to "refresh" the intersector's
cache of objects?

Is this a problem with LineSegmentIntersector and Ortho2D projections? I
presume not, because osgpick works...

I can modify osgpick to try to demonstrate, if that helps.

Has anybody seen anything like this? All pointers appreciated...

David
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to