Hi Brain,

The osgmovie example (in OSG 2.x) has an EvenHandler in it that tracks
the mouse movement and projects this onto the quad and returns the tex
coords, these are then used to imply a position on that texture.  I
wrote this code for exactly the type of thing you are looking to do
right now.

Robert.

On Jan 22, 2008 5:00 PM, Brian <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I am in the process of trying to create an interactive Macromedia Flash 
> drawable.  I am now at the point where the Flash movie is rendering, but it 
> has no available mouse input.  My problem is how to determine what the 
> coordinates of my mouse cursor are (in 2D space) when the mouse is over the 
> drawable.  Preferably, I'd like to know the 2D coordinate of the mouse 
> position in terms of (0..1, 0..1).  The drawable itself is in 3D space.
>
> I know that the IntersectVistor allows me to do certain things, but I have 
> never really used it before.  I've taken a look at the osgPick example and 
> see that I can get the local and world coordinates of an intersection, but I 
> am unclear as to whether there are any helper OSG classes/functions that will 
> allow me to map that intersection point to the correct 2D coordinate to pass 
> to the Flash player.  Also, is it possible to restrict the intersection tests 
>  for my Flash drawables only?
>
> Thanks,
> Brian
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to