dos-vga-arena-shooter-game/bmpload.h

31 lines
524 B
C
Raw Normal View History

2024-02-15 13:34:50 +00:00
#ifndef __BMP_LOADER_H__
#define __BMP_LOADER_H__
2024-02-15 01:15:55 +00:00
#include <stdio.h>
#include "types.h"
struct BMPColor {
byte blue;
byte green;
byte red;
byte _a;
};
struct BMPImage {
int width;
int height;
word bpp;
struct BMPColor colors[256];
byte *memoryStart;
2024-02-15 13:34:50 +00:00
int transparentColor;
2024-02-15 01:15:55 +00:00
};
int readBMPIntoMemory(FILE *, struct BMPImage *);
2024-02-15 13:34:50 +00:00
int readBMPIntoNewMemory(FILE *, struct BMPImage *);
2024-02-15 01:15:55 +00:00
void bmp256ColorPaletteToVGAColorPalette(struct BMPImage*, struct VGAColor[]);
2024-02-16 02:18:15 +00:00
void freeBMP(struct BMPImage *);
2024-02-15 01:15:55 +00:00
2024-02-15 13:34:50 +00:00
#endif