DECLARE SUB DQBcopyLayer (BYVAL SourceLayer, BYVAL DestLayer)
SourceLayer - Source layer to copy data from
DestLayer - Destination layer where to copy data
none
Copies the contents of SourceLayer into DestLayer. All the data previously into DestLayer will be lost. This function can be used to create double buffered animations; just draw every sprite onto a layer on EMS, and then use DQBcopyLayer to copy its contents to the screen.
none
*****************************************************************************
' All integers for speed
DEFINT A-Z
'$INCLUDE:'DIRECTQB.BI'
' Let's initialize the library with one extra layer and no sounds
IF DQBinit(1, 0) THEN DQBclose: PRINT DQBerror$: END
DQBinitVGA
' Draws a box on the hidden layer
DQBbox 1, 0, 0, 319, 199, 15
' Copies the hidden layer on the screen
DQBcopyLayer 1, VIDEO
' Waits for the user to press a key
WHILE INKEY$ = "": WEND
' Ends program
DQBclose
*****************************************************************************