Hi !
Mardi 13 Mars 2001 02:41, Chris Yourch a écrit:
> Is there a way to simulate what WinScreenLock does under 3.5? I would like
> to be able to stop all drawing to the screen somehow.
WinScreenLock does not really stop all drawing.
Think of it as a way to manage 2 screens windows, both located in video RAM.
WinScreenLock allow you to draw offscreen ( on the undisplayed screen ) and
WinScreenUnlock switch these 2 screens ( using hardware flipping ), making
visible the screen where you was drawing, and making 'drawable' the one which
is now not visible, alowing you ( in theory ) to do nice animations.
Unfortunately, the hardware flipping process occur when you call the function
WinScreenUnlock, which mean at any moment, without taking care of the video
sync, and the result is that if do do very fast screen flipping, you can
'see' both screens at the same moment, if the flipping occur when the
'electron beam' was at the middle of the screen...
It will be nice to have a function allowing to sync with the refresh, to
avoid all these visual 'artifacts'.
If you want to simulate WinScreenLock function, just create an offscreen
window, and make it the draw window using WinSetDrawWindow.
This will make all of your drawing functions use your offscreen window.
Then, to simulate WinScreenUnlock, just copy your offscreen window to the
visible screen, by using for exemple WinCopyRectangle.
Regards,
--
Daniel Morais
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/