Hi Himar,

On 6/19/07, Himar Carmona <[EMAIL PROTECTED]> wrote:

hello all,

    does anybody know how can i render only when its needed?

     I'm constructing  a visualization system, and i use OSG 2.0 release.
The application will be a WPF one, and i want to integrate a viewer into the
main window. I have achieved render with it into my own window (i followed
the example about MFC, is it the best method or are there other methods?),
but i just can't use viewer.run, because the main loop will be anywhere
else. I just need to render the view on a WM_PAINT basis, only when needed,
but when i called viewer.frame from my WndProc on paint message it just
call WndProc again (from eventsTraversal). I haven't found yet any clues
about how to resolve this.


viewer.frame() is the best way to only render one frame, and it should work
well. Have you tried to go step by step to follow what's happening when you
call it ?


      Using the source helps, but i'm lacking on a high-level description
of what's going on (i'm new to OSG) and i haven't found any description
about the render loop or the frame cycle or whatever else. (i read the
GettingStartedGuide). I think i have a misconception about how OSG works and
a lot of confusion.

     Any ideas how to do this or where to found information about will be
appreciated.

Thanks everybody, have a nice day and bugfree programs.
Himar





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




--
Serge Lages
http://www.magrathea-engine.org
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Reply via email to