Skip to content

Instantly share code, notes, and snippets.

@alfanick
Created June 10, 2011 21:05
Show Gist options
  • Save alfanick/1019775 to your computer and use it in GitHub Desktop.
Save alfanick/1019775 to your computer and use it in GitHub Desktop.
PALETTE pal;
PACKFILE *file;
/* Open file */
file = pack_fopen(filename, "rb");
if (!file) some_error_func();
/* Read header before palette ... */
/* ... Some header reading code here ;) */
/* Read palette */
pack_fread(&pal, 1024, file);
pack_fclose(file);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment