- [FIX] No guardava be els GIFs sense paleta

This commit is contained in:
2025-06-19 17:48:56 +02:00
parent 76e2925791
commit 0471bcbdda
2 changed files with 2 additions and 2 deletions

View File

@@ -243,7 +243,7 @@ void savesurf(uint8_t surface, const char* filename, uint8_t *pal, uint8_t color
{
uint8_t depth=0;
do { colors = colors >> 1; depth++; } while (colors!=0);
gif::gif_t *file = gif::create(filename, surfaces[surface].w, surfaces[surface].h, pal, (pal?depth:0), -1, -1);
gif::gif_t *file = gif::create(filename, surfaces[surface].w, surfaces[surface].h, pal, (pal?depth:8), -1, -1);
memcpy(file->frame, surfaces[surface].p, surfaces[surface].w*surfaces[surface].h);
gif::addFrame(file, 0);
gif::close(file);