Support of .ICO file loading

only loading the biggest icon

see http://pulkomandy.tk/projects/GrafX2/ticket/69
This commit is contained in:
Thomas Bernard
2018-01-17 00:54:10 +01:00
parent c2c36849b5
commit c2486ed629
3 changed files with 193 additions and 0 deletions

View File

@@ -145,6 +145,10 @@ void Save_PPH(T_IO_Context *);
// Loading is done through SDL_Image
void Save_XPM(T_IO_Context*);
// -- ICO (Windows ICO)
void Test_ICO(T_IO_Context *);
void Load_ICO(T_IO_Context *);
// -- PNG -------------------------------------------------------------------
#ifndef __no_pnglib__
void Test_PNG(T_IO_Context *);
@@ -184,6 +188,7 @@ T_Format File_formats[] = {
{FORMAT_CM5, " cm5", Test_CM5, Load_CM5, Save_CM5, 0, 0, 1, "cm5", "cm5"},
{FORMAT_PPH, " pph", Test_PPH, Load_PPH, Save_PPH, 0, 0, 1, "pph", "pph"},
{FORMAT_XPM, " xpm", NULL, NULL, Save_XPM, 0, 0, 0, "xpm", "xpm"},
{FORMAT_ICO, " ico", Test_ICO, Load_ICO, NULL, 0, 0, 0, "ico", "ico;cur"},
{FORMAT_MISC,"misc.",NULL, NULL, NULL, 0, 0, 0, "", "tga;pnm;xpm;xcf;jpg;jpeg;tif;tiff;ico"},
};