1 /*  Copyright (C) 1996-1997  Id Software, Inc.
2 
3     This program is free software; you can redistribute it and/or modify
4     it under the terms of the GNU General Public License as published by
5     the Free Software Foundation; either version 2 of the License, or
6     (at your option) any later version.
7 
8     This program is distributed in the hope that it will be useful,
9     but WITHOUT ANY WARRANTY; without even the implied warranty of
10     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11     GNU General Public License for more details.
12 
13     You should have received a copy of the GNU General Public License
14     along with this program; if not, write to the Free Software
15     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
16 
17     See file, 'COPYING', for details.
18 */
19 
20 // lbmlib.h
21 
22 typedef unsigned char	UBYTE;
23 typedef short			WORD;
24 typedef unsigned short	UWORD;
25 typedef int				LONG;
26 
27 typedef enum
28 {
29 	ms_none,
30 	ms_mask,
31 	ms_transcolor,
32 	ms_lasso
33 } mask_t;
34 
35 typedef enum
36 {
37 	cm_none,
38 	cm_rle1
39 } compress_t;
40 
41 typedef struct
42 {
43 	UWORD		w,h;
44 	WORD		x,y;
45 	UBYTE		nPlanes;
46 	UBYTE		masking;
47 	UBYTE		compression;
48 	UBYTE		pad1;
49 	UWORD		transparentColor;
50 	UBYTE		xAspect,yAspect;
51 	WORD		pageWidth,pageHeight;
52 } bmhd_t;
53 
54 extern	bmhd_t	bmhd;						// will be in native byte order
55 
56 
57 void LoadLBM (char *filename, byte **picture, byte **palette);
58 
59 void WriteLBMfile (char *filename, byte *data, int width, int height
60 	, byte *palette);
61 
62