mirror of
https://github.com/jmarshall23/CnC_Remastered_Collection.git
synced 2026-08-12 08:00:55 +02:00
29 lines
501 B
C
29 lines
501 B
C
// Image.h
|
|
//
|
|
|
|
struct Image_t {
|
|
Image_t();
|
|
~Image_t();
|
|
|
|
char name[512];
|
|
unsigned int image;
|
|
int width;
|
|
int height;
|
|
int renderwidth;
|
|
int renderheight;
|
|
unsigned char* buffer;
|
|
};
|
|
|
|
__forceinline Image_t::Image_t() {
|
|
buffer = NULL;
|
|
}
|
|
|
|
__forceinline Image_t::~Image_t() {
|
|
if (buffer) {
|
|
delete buffer;
|
|
buffer = NULL;
|
|
}
|
|
}
|
|
|
|
Image_t* Image_LoadImage(const char* name);
|
|
Image_t* Image_CreateImageFrom8Bit(const char* name, int Width, int Height, unsigned char* data, unsigned char *remap = NULL); |