summaryrefslogtreecommitdiff
path: root/csrc/test/dump_600.c
blob: 99d224a922d257aca267f43da3167a2e5dd83ff3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/* gcc -m32 -I.. dump_600.c ../mkf.c ../mkf_00455040.c -o dump_600 */
/* copy Data.mkf and run this, open loading.data with GIMP,
 * data type is RGB565 little endian, size 165*256, it's a tortoise card! */

#include <stdio.h>
#include "mkf.h"

int pixel_fmt = 1;

int main()
{
	int mkf_data = load_mkf("Data.mkf");
	char *data = read_mkf(mkf_data, 600, NULL, NULL);
	FILE *fp = fopen("600.data", "wb");
	fwrite(data, 1, 84480, fp);
	fclose(fp);
	unload_mkf(mkf_data);
}