PDA

View Full Version : Draw an object once time



Shintai
01-26-2015, 07:10 AM
Hi, may I ask a very stupid question?
Is there possible that I could draw an object without redraw in realtime?
For example, after I draw a cube, the cube only redraw if I rotated or rescaled it.

I'm using C# SharpGL
Thank!

uwi2k2
01-26-2015, 08:02 AM
hi,

yes of course you can.
e.g. You draw the cube to a texture in you own FBO ( Frame Buffer Object ).
Or you draw dont redraw the szene till a chenge happend.
So in you render loop like:
if( noChange ) continue;

cu
uwi2k2

Agent D
01-27-2015, 01:08 AM
For something like a simple mesh viewer, you could of course also not blurt out 60ish frames per second and only redraw
the window contents when the window system tells you to, or when the application is requested to rotate/scale the object
you are displaying (which you could do by simply invalidating the window contents over the window system).

Shintai
01-27-2015, 07:52 PM
Thanks for your suggestion!!
It was very helpful