[Scummvm-git-logs] scummvm master -> 38cd2e1cc6d8bc38357c49edfb5e2490593deffa
dreammaster
noreply at scummvm.org
Sat May 25 23:44:30 UTC 2024
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
38cd2e1cc6 M4: Endian fix for cutscene palettes
Commit: 38cd2e1cc6d8bc38357c49edfb5e2490593deffa
https://github.com/scummvm/scummvm/commit/38cd2e1cc6d8bc38357c49edfb5e2490593deffa
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2024-05-25T16:44:24-07:00
Commit Message:
M4: Endian fix for cutscene palettes
Changed paths:
engines/m4/wscript/ws_load.cpp
diff --git a/engines/m4/wscript/ws_load.cpp b/engines/m4/wscript/ws_load.cpp
index 1ab66aa524f..611d6eb40df 100644
--- a/engines/m4/wscript/ws_load.cpp
+++ b/engines/m4/wscript/ws_load.cpp
@@ -1506,7 +1506,6 @@ static int32 GetSSHeaderInfo(SysFile *sysFile, uint32 **data, RGB8 *myPalette) {
uint32 *tempPtr, i, j, header, format;
int32 numCels, dataOffset;
bool byteSwap;
- void *handlebuffer;
if (!sysFile) {
ws_LogErrorMsg(FL, "nullptr FILE POINTER given.");
@@ -1556,11 +1555,9 @@ static int32 GetSSHeaderInfo(SysFile *sysFile, uint32 **data, RGB8 *myPalette) {
}
// Read in the color info into a temp buffer
- handlebuffer = myColors;
- if (!(*sysFile).read(&handlebuffer, numColors << 2)) {
- ws_LogErrorMsg(FL, "Failed to read in the PAL color info.");
- return -1;
- }
+ for (i = 0; i < numColors; ++i)
+ myColors[i] = sysFile->readUint32LE();
+
// If the chunk is in the wrong format, byte-swap the entire chunk
// note: we do this because we want the data stored in nrgb format
More information about the Scummvm-git-logs
mailing list