48 #define MAX_BITMAPS 4750 
   52 #define BMP_AABITMAP        (1<<0)       
   53 #define BMP_TEX_XPARENT     (1<<1)       
   54 #define BMP_TEX_OTHER       (1<<2)       
   55 #define BMP_TEX_DXT1        (1<<3)       
   56 #define BMP_TEX_DXT3        (1<<4)       
   57 #define BMP_TEX_DXT5        (1<<5)       
   58 #define BMP_TEX_CUBEMAP     (1<<6)       
   61 #define BMP_TEX_COMP        ( BMP_TEX_DXT1 | BMP_TEX_DXT3 | BMP_TEX_DXT5 )   
   62 #define BMP_TEX_NONCOMP     ( BMP_TEX_XPARENT | BMP_TEX_OTHER )              
   63 #define BMP_TEX_ANY         ( BMP_TEX_COMP | BMP_TEX_NONCOMP )               
   66 #define BMP_FLAG_RENDER_TARGET_STATIC       (1<<0)       
   67 #define BMP_FLAG_RENDER_TARGET_DYNAMIC      (1<<1)       
   68 #define BMP_FLAG_CUBEMAP                    (1<<2)       
  184         float map_texture_address(
float address);
 
  257 int bm_unload(
int handle, 
int clear_render_targets = 0, 
bool nodebug = 
false);
 
  287 int bm_release(
int handle, 
int clear_render_targets = 0);
 
  383 int bm_get_info(
int handle, 
int *
w = NULL, 
int * 
h = NULL, 
ubyte * 
flags = NULL, 
int *nframes = NULL, 
int *fps = NULL);
 
void bm_set_low_mem(int mode)
Sets BMPMAN's memory mode. 
 
ubyte bpp
Requested bitdepth of each pixel. ( 7, 8, 15, 16, 24, 32) 
 
generic DDS cubemap (uncompressed cubemap surface) 
 
int bm_unload(int handle, int clear_render_targets=0, bool nodebug=false)
Unloads a bitmap's data, but not the bitmap info. 
 
const BM_TYPE bm_type_list[]
List of valid bitmap types. 
 
int bm_get_tcache_type(int handle)
Gets the correct TCACHE_TYPE for compressed graphics (uncompressed are assumed TCACHE_TYPE_NORMAL) ...
 
void bm_get_palette(int handle, ubyte *pal, char *name)
Gets the palette for a given bitmap indexed by handle, and optionally the filename. 
 
GLfloat GLfloat GLfloat GLfloat h
 
int bm_get_num_mipmaps(int handle)
Gets the number of mipmaps of the indexed texture. 
 
const char * bm_ext_list[]
List of extensions for those types. 
 
void bm_unlock(int handle)
Unlocks a bitmap. 
 
24-bit cubemap (compressed cubemap surface) 
 
ubyte true_bpp
The image's actual bitdepth. 
 
ubyte flags
Various texture type flags. 
 
void bm_set_components_argb_32_screen(ubyte *pixel, ubyte *r, ubyte *g, ubyte *b, ubyte *a)
Sets the 32bpp screen pixel to the specified RGBA value. 
 
bool bm_load_and_parse_eff(const char *filename, int dir_type, int *nframes, int *nfps, int *key, BM_TYPE *type)
Loads and parses an .EFF. 
 
int bm_get_info(int handle, int *w=NULL, int *h=NULL, ubyte *flags=NULL, int *nframes=NULL, int *fps=NULL)
Gets info on the bitmap indexed by handle. 
 
bool bm_has_alpha_channel(int handle)
Checks to see if the indexed bitmap has an alpha channel. 
 
bool bm_page_out(int handle)
Unloads the bitmap indexed by handle that was previously paged-in. 
 
int bm_get_cache_slot(int bitmap_id, int separate_ani_frames)
 
void bm_get_components(ubyte *pixel, ubyte *r, ubyte *g, ubyte *b, ubyte *a)
Gets the RGBA components of a pixel according to the selected mode. 
 
const int BM_NUM_TYPES
Calculated number of bitmap types. 
 
std::basic_string< char, std::char_traits< char >, std::allocator< char > > SCP_string
 
void bm_update_memory_used(int n, int size)
(DEBUG) Similar to bm_malloc, but only updates how much memory is used 
 
void bm_get_frame_usage(int *ntotal, int *nnew)
(DEBUG) Gets memory size, in bytes, of the locked bitmaps 
 
short h
Height, in number of pixels. 
 
int bm_reload(int bitmap_handle, const char *filename)
Reloads an existing bmpman slot with different bitmap. 
 
ubyte * palette
Pointer to this bitmap's palette (if it has one). 
 
int bm_make_render_target(int width, int height, int flags)
Creates a render target as close to the desired resolution as possible. 
 
int bm_unload_fast(int handle, int clear_render_targets=0)
Quickly unloads a bitmap's data, ignoring the load_count. 
 
GLenum GLuint GLint GLenum face
 
void bm_unload_all()
Unloads all used bitmaps, should only ever be called by game_shutdown() 
 
void bm_set_components_argb_16_tex(ubyte *pixel, ubyte *r, ubyte *g, ubyte *b, ubyte *a)
Sets the 16bpp texture pixel to the specified RGBA value. 
 
GLdouble GLdouble GLdouble r
 
GLboolean GLboolean GLboolean GLboolean a
 
int Bm_paging
Bool type that indicates if BMPMAN is currently paging. 
 
specifies any type of animated image, the EFF itself is just text 
 
const BM_TYPE bm_ani_type_list[]
List of valid bitmap animation types. 
 
int bm_is_valid(int handle)
Checks if the bitmap indexed by handle is valid. 
 
void(* bm_set_components)(ubyte *pixel, ubyte *r, ubyte *g, ubyte *b, ubyte *a)
Functional pointer that references any of the bm_set_components functions. 
 
24 bit with switchable alpha 
 
short w
Width, in number of pixels. 
 
BM_TYPE bm_get_type(int handle)
Returns the image type of the given bitmap handle. 
 
short rowsize
What you need to add to go to next row. 
 
32-bit cubemap (compressed cubemap surface) 
 
void bm_page_in_xparent_texture(int bitmapnum, int num_frames=1)
Marks a textures as being used for level and is transparant. 
 
int bm_load_either(const char *filename, int *nframes=NULL, int *fps=NULL, int *keyframe=NULL, int can_drop_frames=0, int dir_type=CF_TYPE_ANY)
Loads either animation (bm_load_animation) or still image (bm_load) 
 
float get_channel_alpha(float u, float v)
 
void BM_SELECT_ALPHA_TEX_FORMAT()
Sets bm_set_components and bm_get_components to reference texture format functions (with alpha) ...
 
float get_channel_blue(float u, float v)
 
void bm_page_in_texture(int bitmapnum, int num_frames=0)
Marks a texture as being used for this level. 
 
void * bm_malloc(int handle, int size)
Allocates memory for the given handle. 
 
int bm_create(int bpp, int w, int h, void *data=NULL, int flags=0)
 
void bm_get_filename(int bitmapnum, char *filename)
Gets the filename of the bitmap indexed by handle. 
 
void bm_page_in_aabitmap(int bitmapnum, int num_frames=1)
Marks a texture as being used for this level, and is anti-aliased. 
 
bitmap_lookup(int bitmap_num)
 
float get_channel_green(float u, float v)
 
size_t bm_get_size(int handle)
Gets the size, in bytes, taken up by the bitmap indexed by handle. 
 
void bm_close()
Closes the bitmap manager, freeing any allocated memory used by bitmaps. Is called at program close...
 
void bm_set_components_argb_32_tex(ubyte *pixel, ubyte *r, ubyte *g, ubyte *b, ubyte *a)
Sets the 32bpp texture pixel to the specified RGBA value. 
 
const int BM_ANI_NUM_TYPES
Calculated number of bitmap animation types. 
 
void bm_gfx_load_all()
Loads all data for all bitmaps that have been requested to be loaded. 
 
24/32 bit setup internally as a dynamic render target 
 
int MISCMAP
Utility map, to be utilized for various things shader authors can come up with. 
 
typedef void(APIENTRY *PFNGLARRAYELEMENTEXTPROC)(GLint i)
 
GLuint const GLchar * name
 
GLboolean GLboolean GLboolean b
 
int bm_is_render_target(int handle)
Checks to see if the given bitmap indexed by handle is a render target. 
 
void BM_SELECT_SCREEN_FORMAT()
Sets bm_set_components and bm_get_components to reference screen format functions. 
 
GLint GLsizei GLsizei height
 
GLubyte GLubyte GLubyte GLubyte w
 
int bm_texture_ram
how many bytes of textures are used. 
 
uint bm_get_signature(int handle)
Returns a unique signiature for the bitmap indexed by handle. 
 
void bm_page_in_stop()
Tells bmpman to stop paging (?) 
 
const char * bm_ani_ext_list[]
List of extensions for those types. 
 
generic identifier for DDS 
 
int bm_get_next_handle()
Gets the next available bitmap slot. 
 
bool bm_set_render_target(int handle, int face=-1)
(GR function) Calls gr_bm_set_render target for the given bitmap indexed by handle ...
 
int bm_is_compressed(int handle)
Returns the compression type of the bitmap indexed by handle. 
 
GLenum GLsizei GLenum GLenum const GLvoid * data
 
int bm_release(int handle, int clear_render_targets=0)
Frees both a bitmap's data and it's associated slot. 
 
24/32 bit setup internally as a static render target 
 
int HEIGHTMAP
Height map for normal mapping. 
 
ptr_u data
Pointer to data, or maybe offset into VRAM. 
 
void bm_set_components_argb_16_screen(ubyte *pixel, ubyte *r, ubyte *g, ubyte *b, ubyte *a)
Sets the 16bpp screen pixel to the specified RGBA value. 
 
void bm_page_in_start()
Tells bmpman to start keeping track of what bitmaps are used where. 
 
void bm_gfx_get_pixel(int bitmap, float u, float v, ubyte *r, ubyte *g, ubyte *b)
Hack to get a pixel from a bitmap. 
 
int NORMMAP
Normal mapping. 
 
32-bit cubemap (compressed cubemap surface) 
 
void BM_SELECT_TEX_FORMAT()
Sets bm_set_components and bm_get_components to reference texture format functions. 
 
int bm_load_animation(const char *filename, int *nframes=NULL, int *fps=NULL, int *keyframe=NULL, int can_drop_frames=0, int dir_type=CF_TYPE_ANY)
Loads a bitmap sequance so we can draw with it. 
 
bitmap * bm_lock(int handle, ubyte bpp, ubyte flags, bool nodebug=false)
Locks down the bitmap indexed by bitmapnum. 
 
int bm_load_duplicate(const char *filename)
Reloads a bitmap as a duplicate. 
 
void(* bm_set_components_32)(ubyte *pixel, ubyte *r, ubyte *g, ubyte *b, ubyte *a)
Functional pointer that references any of the bm_set_components_32 functions. 
 
float get_channel_red(float u, float v)
 
int ENVMAP
References a map that is for environment mapping -Bobboau. 
 
int bm_load(const char *filename)
Loads a bitmap so we can draw with it later. 
 
void bm_print_bitmaps()
(DEBUG) Prints all loaded bitmaps to an outwindow 
 
void bm_init()
Initilizes the bitmap manager. 
 
int SPECMAP
References a map that is for specular mapping -Bobboau. 
 
int GLOWMAP
References a map that is a fully lit version of its index -Bobboau.