pokemon PNGs and palettes

This commit is contained in:
YamaArashi
2015-11-13 21:57:22 -08:00
parent 3d1b6597f3
commit 4c733f3811
2871 changed files with 19547 additions and 2830 deletions
+36
View File
@@ -0,0 +1,36 @@
// Copyright (c) 2015 YamaArashi
#ifndef GFX_H
#define GFX_H
#include <stdint.h>
#include <stdbool.h>
struct Color {
unsigned char red;
unsigned char green;
unsigned char blue;
};
struct Palette {
struct Color colors[256];
int numColors;
};
struct Image {
int width;
int height;
int bitDepth;
unsigned char *pixels;
bool hasPalette;
struct Palette palette;
bool isObject;
};
void ReadImage(char *path, int tilesWidth, int bitDepth, struct Image *image, bool invertColors);
void WriteImage(char *path, int numTiles, int bitDepth, struct Image *image, bool invertColors);
void FreeImage(struct Image *image);
void ReadGbaPalette(char *path, struct Palette *palette);
void WriteGbaPalette(char *path, struct Palette *palette);
#endif // GFX_H