Drawing Window mode & sync
Posted: Thu Jul 24, 2014 3:46 pm
Clearing screen or what is best practice having
I am opening a window with:
If CreateImage(0, 640, 480) And OpenWindow(0,0,0,640,480,"Fractal Lines",#PB_Window_SystemMenu)
...
and do simple 2d drawing (linexy) with
StartDrawing(ImageOutput(0))
StopDrawing()
but how can I clear the window and wait for sync with monitor refresh so I can render an realtime animation without flickering?
actually I need windowed screen where I can simply draw with the basic 2d functions (setting pixels, drawing lines, not sprites etc)... and clear it (without doing a fake BOX draw with background color).
and best... without flickering as waiting for a sync?
Thanks for help here again.
I am opening a window with:
If CreateImage(0, 640, 480) And OpenWindow(0,0,0,640,480,"Fractal Lines",#PB_Window_SystemMenu)
...
and do simple 2d drawing (linexy) with
StartDrawing(ImageOutput(0))
StopDrawing()
but how can I clear the window and wait for sync with monitor refresh so I can render an realtime animation without flickering?
actually I need windowed screen where I can simply draw with the basic 2d functions (setting pixels, drawing lines, not sprites etc)... and clear it (without doing a fake BOX draw with background color).
and best... without flickering as waiting for a sync?
Thanks for help here again.