I've made some research (should have begin with that ?) and 
apparently while it would be possible to have SDL handle 
the window and inputs, and OSG do only the rendering, this 
is not advisable:

"Personally I wouldn't recommend SDL for windowing for 
serious 3d graphics applications, its just way too 
limiting - its really just designed for single threaded, 
single context apps."

http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/2007-August/000558.html

That was in August 2007: is it still the situation today ?




"Another way to do it is just use SDL for joysticks, and use 
the standard osgViewer's support for native windowing."

http://www.mail-archive.com/[EMAIL PROTECTED]/msg12744.html

That's what I do today. But it's conceptually un-nice.



Any suggestions ?

bye

Zoltán




Zoltán wrote on Tuesday 06 May 2008:

> I have an OSG application that uses joysticks, and I use
> SDL for those. But I also need a mouse and keyboard and
> use (today) OSG for that. Sometimes it's a bit messy to
> do this, because when there is no joystick connected I
> fall back to the mouse, and the interface is very
> different (one is a SDL_JOYSTICk and the other an
> osgEventHandler). I'd like to handle mouse and joystick
> from the same interface, so either make both of them
> through SDL or both of them an osgEventHandler.
>
> Wouldn't it be more coherent to use SDL for all input ?
> But then, I need to create the window with SDL, and embed
> the osgViewer inside this window. Is this a reliable way
> to do things ? Because if I create the window with OSG,
> SDL doesn't "see" the mouse and keyboard.
>
> Or, is there a way to make an osgEventHandler from a
> SDL_JOYSTICK interface ? There is an osgviewerSDL in the
> examples (v2.3.4) but this is for an embedded OSG viewer
> inside an SDL window... would those work with a joystick
> ?
>
> Any suggestions ?
>
> cheers
>
> Zoltán
>
>
>
> PS: the application in question is a flight simulator:
> http://sourceforge.net/projects/zsim



-- 
 
____________________________________

Zoltan

http://sourceforge.net/projects/zsim
____________________________________

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

Reply via email to