fxconv: fix double object file size for RGB565 images

This commit is contained in:
Lephenixnoir 2022-07-16 17:23:14 +01:00
parent 00b85297a3
commit a7046966da
Signed by: Lephenixnoir
GPG Key ID: 1BBA026E13FC0495
1 changed files with 1 additions and 1 deletions

View File

@ -1033,7 +1033,7 @@ def image_encode(img, format):
if format.depth == IMAGE_RGB16:
# Preserve alignment between rows by padding to 4 bytes
stride = (img.width + 1) // 2 * 4
size = stride * img.height * 2
size = stride * img.height
elif format.depth == IMAGE_P8:
size = img.width * img.height
stride = img.width