Ensure that the palette does not have more than 256 values

This commit is contained in:
Mirco Miranda
2026-10-30 14:29:57 +01:00
committed by Mirco Miranda
parent e2c6317079
commit 59157971e8
6 changed files with 62 additions and 6 deletions
+1 -1
View File
@@ -652,7 +652,7 @@ static bool LoadTGA(QIODevice *dev, const TgaHeader &tga, QImage &img)
return false;
}
img.setColorTable(colorTable);
img.setColorTable(truncTo8BitColorTable(colorTable));
}
// Convert image to internal format.