mirror of
https://github.com/sfall-team/sfall.git
synced 2026-07-27 16:52:34 -07:00
Fixed movie scale pitch size for CPU palette conversion
This commit is contained in:
+1
-1
@@ -3,7 +3,7 @@
|
||||
|
||||
[Main]
|
||||
;Set to 1 to enable the built-in High Resolution Patch mode that is similar to the hi-res patch by Mash
|
||||
;The required settings will be read from f2_res.ini configuration file from the original hi-res patch
|
||||
;The required settings will be read from the f2_res.ini configuration file of the original hi-res patch
|
||||
HiResMode=1
|
||||
|
||||
;Set to 1 if you want to use command line arguments to tell sfall to use another ini file
|
||||
|
||||
@@ -645,6 +645,7 @@ public:
|
||||
fo::func::buf_to_buf(mveSurface, width, mveDesc.dwHeight, width, (BYTE*)dRect.pBits, dRect.Pitch);
|
||||
}
|
||||
} else {
|
||||
int sPitch = width;
|
||||
int height = mveDesc.dwHeight;
|
||||
|
||||
if (d != 0) { // scale
|
||||
@@ -653,7 +654,9 @@ public:
|
||||
height = dst->bottom - dst->top;
|
||||
|
||||
HRP::Image::Scale(mveSurface, mveDesc.lPitch, mveDesc.dwHeight, mveScaleSurface, width, height, ResWidth);
|
||||
|
||||
mveSurface = mveScaleSurface;
|
||||
sPitch = ResWidth;
|
||||
}
|
||||
|
||||
int pitch = dRect.Pitch / 4;
|
||||
@@ -662,7 +665,7 @@ public:
|
||||
while (height--) {
|
||||
int x = width;
|
||||
while (x--) pBits[x] = palette[mveSurface[x]].xRGB;
|
||||
mveSurface += width;
|
||||
mveSurface += sPitch;
|
||||
pBits += pitch;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user