mirror of
https://github.com/Almamu/linux-wallpaperengine.git
synced 2025-09-14 13:56:48 +08:00
fix: parsing tex0004
This commit is contained in:
parent
e5355d0013
commit
958c97f791
@ -284,7 +284,7 @@ std::unique_ptr<CTexture::TextureHeader> CTexture::parseHeader (const char* file
|
|||||||
header->freeImageFormat = static_cast<FreeImageFormat> (*pointer++);
|
header->freeImageFormat = static_cast<FreeImageFormat> (*pointer++);
|
||||||
header->isVideoMp4 = *pointer++ == 1;
|
header->isVideoMp4 = *pointer++ == 1;
|
||||||
|
|
||||||
if (header->freeImageFormat == FIF_UNKNOWN) {
|
if (header->freeImageFormat == FIF_UNKNOWN && header->isVideoMp4) {
|
||||||
header->freeImageFormat = FIF_MP4;
|
header->freeImageFormat = FIF_MP4;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -412,6 +412,8 @@ std::shared_ptr<CTexture::TextureMipmap> CTexture::parseMipmap (const TextureHea
|
|||||||
fileData ++;
|
fileData ++;
|
||||||
|
|
||||||
pointer = reinterpret_cast<const uint32_t*> (fileData);
|
pointer = reinterpret_cast<const uint32_t*> (fileData);
|
||||||
|
// this is another param to ignore
|
||||||
|
pointer++;
|
||||||
}
|
}
|
||||||
|
|
||||||
mipmap->width = *pointer++;
|
mipmap->width = *pointer++;
|
||||||
|
Loading…
Reference in New Issue
Block a user