[comp.sys.amiga] Proper rendering in superbitmap bitmap.

dale@amiga.UUCP (Dale Luck) (05/09/87)

The SuperBitmap does not keep all the bits of the window in the
allocated bitmap. If a line is drawn the is in the displayed portion
of the bitmap, it is only drawn in the window and is not also
drawn in the backup bitmap. When the application programmer needs
to diddle with the bits with his own processor code, he may syncronize
the backup bitmap with what maybe on the screen. 'SyncSBitMap'
This will transfer the missing bits from the window in the the real
superbitmap. The program can then do what ever it needs with those bits.
When done, the program must call 'CopySBitMap' to get the new bits
out to the displayed window. When dealing with intuition and all those
users that insist on resizing the windows. You need to encase these calls
with LockLayer calls.

If Layer is a pointer to the layer associated with a superbitmap window
then.

LockLayer(Layer)	Prevents corruption of Cliprects, etc.
SyncSBitMap(Layer)	CopyBits into master bitmap
mungebits()		You supply this.
CopySBitMap(Layer)	CopyBits back out to waiting window
UnlockLayer(Layer)	Resume normal operation

Dale Luck, just one of the guys.