File: loader.hpp

package info (click to toggle)
abuse 2.00-12
  • links: PTS
  • area: main
  • in suites: slink
  • size: 12,708 kB
  • ctags: 15,389
  • sloc: ansic: 115,852; cpp: 6,792; lisp: 2,066; sh: 1,734; makefile: 1,601; asm: 264
file content (41 lines) | stat: -rw-r--r-- 1,024 bytes parent folder | download | duplicates (4)
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
#ifndef __LOADER_HPP_
#define __LOADER_HPP_
#include "image.hpp"
#include "palette.hpp"
#include "image24.hpp"


// supported graphics file formats so far..

enum graphics_type 
{ LOADER_not_supported,
  LOADER_mdl,	              // propritary
  LOADER_spe,		      // propritary
  LOADER_ppm,		      // portable pixmap
  LOADER_bmp8,		      // 8 bit color Microsoft Bitmap	
  LOADER_bmp24,		      // 24 bit color Microsoft Bitmap
  LOADER_pcx8,		      // 8 bit color PC paintbrush
  LOADER_pcx24,		      // 24 bit color PC paintbrush
  LOADER_xwd,		      // X-window dump format
  LOADER_pic,	              // Pic (used in Gl's)
  LOADER_lbm,                 // Delux Paint
  LOADER_targa                // 24 bit, converted to 8 on load though
} ;

graphics_type tell_file_type(char *filename);
int tell_color_size(char *filename);     // returns 8 or 24 
short load_any(char *filename, image **&images, 
	       palette *&pal, short &total_read, palette *ref_pal=0);
image24 *load_any24(char *filename);

#endif