A simple 256-color palette viewer.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

31 lines
624 B

/* main.c - Program entry point. */
#include <stdio.h>
#include "defs.h"
#include "game.h"
#include "video.h"
int main(int argc, char **argv) {
SDL_bool vga = SDL_FALSE;
if(argc < 2) {
printf("\n usage: palview (palette file) [vga]\n\n");
printf(" vga should be 1 if the palette is a VGA palette (color range: 0x00-0x3F,\n");
printf(" otherwise it should be 0. If not specified, it will default to 0.\n\n");
return 1;
}
if(argc > 2) {
printf("vga: %s\n", argv[2]);
if(strncmp(argv[2], "1", 1) == 0)
vga = SDL_TRUE;
}
game_loop(argv[1], vga);
video_close();
SDL_Quit();
return 0;
}