Hi Gian

On 2/15/07, Gian Lorenzetto <[EMAIL PROTECTED]> wrote:

Hi Thibault, Robert,

[...]

My current goal is to get it compiling this weekend and then onto the
Wiki for others to help fix as I simply don't have the time to debug
this myself.


I'll be happy to test your code on monday then :)

To answer your questions:

> >  1) I have used wxWidgets "old way" of instantiating OpenGL
contexts; that
> > is, 2.8 introduced an explicit context creation and usage with
> > SetCurrent(context), but this does not work

I haven't built any code against 2.8.0 so can't really comment here ...
other than to say that with 2.6.x I let the wxGLCanvas handle the
context creation. Check out the (now severely outdated) example on the
OSG wiki.


Things do work with the the 2.6.x method -- the 2.8.x manual suggests that
we should use the new method, but I don't really see the point. I'm happy
with the 2.6.x way, but it might be a good idea to try it in the future
osgviewerWx.

>  2) I am wondering whether I should use different OpenGL contexts.
[...]
I've successfully used multiple views (4 at a time) each with its own
opengl context and SceneView. Be sure to set the ContextID on each
SceneView as per this FAQ item:

http://www.openscenegraph.org/osgwiki/pmwiki.php/FAQ/FAQ#faq_40


Ahh I knew there was something to do at the OSG level. I just could not find
it. It works now, thanks !

>  3) My trackball manipulator shows erratic behaviour: the rotations
occur
> > only by 90 degrees, and if I move my mouse by 1 pixels, the model
jumps by
> > 200 pixels or so. I've read in the archives that trackball speed is
> > hardcoded, but my behaviour seems suspicious. Any idea ?

Can't help here, works fine for me. The example on the wiki shows how I
capture events from wx and pipe them into OSG. Again, the example is
against OSG 1.2, so YMMV


I'll have a deep look at that now that the context issue is solved.

>  4) Can I use, in the same process, different threads to render to
the
> > different GL widgets ? I'd love to have the main thread manage the
wx stuff,
> > and one thread per graphics window.

Never tried, but I don't see why not, as long as you manage the contexts
properly.


Yes, contexts are one key. I'll try and will keep the list informed.
But wxWidgets, in a general way, do not like multi-threading that much.
Normally, only one thread can call the library (worker threads are possible,
though) but I'll try to get the OSG draw in its window from a separate
thread.

>  5) Should I wait for the new osgViewer class to come out ? Or maybe
I can
> > help with osgviewerWX (since I've seen in the CVS that no such
viewer is
> > currently being worked on)

You are more than welcome to help out with osgviewerWx if you like. I'll
post my code on the weekend.


Okay, keep us informed.

Thank you very much

Cheers,
Thibault
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Reply via email to