aboutsummaryrefslogtreecommitdiff
path: root/DPIFF.H
blob: 614558d5e37d670e3b56df465fcf4bf2a07b0c12 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
/** dpiff.h ******************************************************************/
/*                                                                           */
/* DPAINT IFF file I/O procedures                                            */
/*                                                                           */
/*****************************************************************************/
#ifndef DPIFF_H
#define DPIFF_H

#include "iff\ilbm.h"

#define BAD_FIT  -9

extern IFFP IffErr();	/* returns an IFFP error code; see IFF.H */

/* FLAGS */
#define MBM_HAS_GRAB 1
#define MBM_HAS_PUSE 2
#define MBM_HAS_CMAP 4
#define MBM_HAS_RANGES 8

/* Range id */
#define ID_CRNG		MakeID('C','R','N','G')

typedef BOOL (*ResizeProc)();

typedef struct {
    LONG flags;
    struct BitMap *bitmap;
    SHORT w;			/* pixel width of bitmap */
    UBYTE xAspect, yAspect;
    Masking masking;
    UBYTE *mask;
    UBYTE xpcolor;
    Point2D pos;
    Point2D grab;
    Range *ranges;
    SHORT nRange;
    } MaskBM;
    
extern BOOL PutMaskBM(LONG, MaskBM *, WORD *, BYTE *, LONG);
/*		     file, maskBM, colorMap, buffer, bufsize */
 
extern BOOL GetMaskBM(LONG, MaskBM *, WORD *, ResizeProc,  BYTE *,LONG );
/*     file  maskBM  colorMap   reSize()  buffer  bufsize	*/