|
| void | _bitmapchk (void) |
| void | _bitloadchk (void) |
| void | bitmaplib_sbchk (void) |
| void | cbchk (void) |
| void | cludgechk (void) |
| void | shchk (void) |
| void | _usechk (void) |
| void | extbitmap (void) |
| void | _bitmap (UWORD w, UWORD h, UWORD d, WORD usedoff) |
| | BitMap BitMap#,Width,Height,Depth: a new bitmap in chip memory.
|
| void | _bitload (const UBYTE *name, struct bb_bitmap *bm) |
| | LoadBitMap BitMap#,Filename$: load an ILBM into the bitmap.
|
| void | _bitload2 (const UBYTE *name, APTR pal, struct bb_bitmap *bm) |
| | LoadBitMap BitMap#,Filename$,Palette#: LoadBitMap, first the palette (palettelib +3, a0 = name, a1 = palette).
|
| void | doscbitmap (UBYTE **scr, WORD usedoff) |
| | ScreensBitMap Screen#,BitMap#: the bitmap of a screen (borrowed, isreal = 1).
|
| void | docopybitmap (struct bb_bitmap *src) |
| | CopyBitMap Src BitMap#,Dest BitMap#: a copy of the source bitmap in own chip memory.
|
| void | doshbitmap (const struct bb_shape *shape, WORD usedoff) |
| | ShapesBitMap Shape#,BitMap#: a bitmap on the planes of a shape (borrowed, isreal = 1).
|
| void | _cludgebitmap (UWORD w, UWORD h, UWORD d, ULONG mem, WORD usedoff) |
| | CludgeBitMap BitMap#,Width,Height,Depth,Memory: a bitmap in memory of the program (borrowed, isreal = 1).
|
| void | _freebitmap (void) |
| | Free BitMap (the object's _free nullsub): free the planes of the bitmap in a3 if they are its own memory (isreal < 0).
|
| static void | setused (WORD off) |
| static ULONG | bmbytes (UWORD rows, UWORD depth, UWORD bpr) |
| static void | freebitmap (struct bb_bitmap *b) |
| static void | prepxtra (struct bb_bitmap *b) |
| static void | ext (struct bb_bitmap *b, UWORD w, UWORD h, UWORD d) |
| static void | extbitmap_c (UWORD w, UWORD h, UWORD d) |
| | extbitmap (nullsub, for other libraries): allocate and set up the bitmap in a3 without freeing it first.
|
| static void | bmsize (WORD w, WORD h) |
| static void | _bitmapchk_c (WORD w, WORD h, UWORD d) |
| static void | cludgechk_c (WORD w, WORD h, UWORD d) |
| static void | _usechk_c (void) |
| static void | _bitloadchk_c (const struct bb_bitmap *b) |
| static void | sbchk_c (const ULONG *s) |
| static void | shchk_c (const ULONG *s) |
| static void | cbchk_c (const struct bb_bitmap *b) |
| void _bitload2 |
( |
const UBYTE * | name, |
|
|
APTR | pal, |
|
|
struct bb_bitmap * | bm ) |
LoadBitMap BitMap#,Filename$,Palette#: LoadBitMap, first the palette (palettelib +3, a0 = name, a1 = palette).
Amiga mode only. Errors (debugger, _bitloadchk): "Uninitialized
BitMap".
- Parameters
-
| name | d1: the file name |
| pal | a0: the palette (!libs {palettelib,$1082}) |
| bm | a1: the bitmap (!libs {bitmaplib,$1180}) |
| void _bitmap |
( |
UWORD | w, |
|
|
UWORD | h, |
|
|
UWORD | d, |
|
|
WORD | usedoff ) |
BitMap BitMap#,Width,Height,Depth: a new bitmap in chip memory.
Becomes the used bitmap; frees the old one, isreal = -1 (own memory), then as extbitmap (fixed, #76: the size is a long product); the plane pointers beyond the depth are cleared (fixed, #80: the original left what the object held). Errors (debugger, _bitmapchk): "Illegal BitMap Depth" if the depth is 0 or more than 8 (fixed, #1040: the original raised error number 1, "No currently used
object!"); "Illegal BitMap Size" for a width or height below 1 (fixed, #78: not in the original). The bitmap object comes in a3 (!libs {bitmaplib,$1380/$1381}).
- Parameters
-
| w | d1.w: the width in pixels |
| h | d2.w: the height |
| d | d3.w: the depth |
| usedoff | d6: offset of the used bitmap from a5 (!libs {bitmaplib,$0604}); it becomes this bitmap |
| void _cludgebitmap |
( |
UWORD | w, |
|
|
UWORD | h, |
|
|
UWORD | d, |
|
|
ULONG | mem, |
|
|
WORD | usedoff ) |
CludgeBitMap BitMap#,Width,Height,Depth,Memory: a bitmap in memory of the program (borrowed, isreal = 1).
Becomes the used bitmap; frees the old one; the planes follow each other in the memory. No interleave check: not a bug (no visible effect, #77): +52 is cleared, the plane distance +54 stays from before. The bitmap object comes in a3 (!libs {bitmaplib,$1380/$1381}). Errors (debugger, cludgechk): "Illegal BitMap Depth" for a depth of 0 or more than 8 (fixed, #393 #74: the original had no check); "Illegal
BitMap Size" for a width or height below 1 (fixed, #78).
- Parameters
-
| w | d1.w: the width in pixels |
| h | d2.w: the height |
| d | d3.w: the depth |
| mem | d4: the memory (chip memory for display/blits) |
| usedoff | d6: offset of the used bitmap from a5 (!libs {bitmaplib,$0604}); it becomes this bitmap |
CopyBitMap Src BitMap#,Dest BitMap#: a copy of the source bitmap in own chip memory.
Frees the destination, allocates one MEMF_CHIP block (not cleared) and copies plane by plane. BUG(orig): (bytes per row * rows) / 2 words per plane, 0 words = 4 billion (#78: such a source is refused at its creation with runtime error checking); the size is a long product (fixed, #76). Not a bug: the used bitmap is not set (CopyBitMap is not documented to select it). Errors (debugger, cbchk): "Can't copy
borrowed Bitmap" (the destination is borrowed).
- Parameters
-
| src | a2: the source bitmap (!libs {bitmaplib,$1280}); the destination comes in a3 ($1381) |
| void doscbitmap |
( |
UBYTE ** | scr, |
|
|
WORD | usedoff ) |
ScreensBitMap Screen#,BitMap#: the bitmap of a screen (borrowed, isreal = 1).
Becomes the used bitmap; frees the old one, copies the screen's struct BitMap (RastPort.BitMap, 40 bytes), then the extra fields. Errors (debugger, sbchk): "Uninitialized Screen".
- Parameters
-
| scr | a2: the screen object (!libs {screenslib,$1280}): its Screen; the bitmap comes in a3 ($1381) |
| usedoff | d6: offset of the used bitmap from a5 (!libs {bitmaplib,$0604}); it becomes this bitmap |
| void doshbitmap |
( |
const struct bb_shape * | shape, |
|
|
WORD | usedoff ) |
ShapesBitMap Shape#,BitMap#: a bitmap on the planes of a shape (borrowed, isreal = 1).
Becomes the used bitmap; frees the old one; bytes per row, rows and depth from the shape. Fixed (#79): the plane size is added unsigned (the original added it as a sign extended word: planes of 32 KB and more pointed backwards). Errors (debugger, shchk): "Uninitialized Shape".
- Parameters
-
| shape | a2: the shape (!libs {shapeslib,$1280}); the bitmap comes in a3 ($1381) |
| usedoff | d6: offset of the used bitmap from a5 (!libs {bitmaplib,$0604}); it becomes this bitmap |