The rules have been updated, read them now: Rules!

Serious Sam (HD, 3) unknown texture package

Get your graphics formats figures out here! Got details for others? Post here!
Post Reply
0ther1
n00b
Posts: 13
Joined: Thu Apr 30, 2020 3:56 am
Been thanked: 4 times

Serious Sam (HD, 3) unknown texture package

Post by 0ther1 » Sat Feb 27, 2021 5:07 pm

Textures in Serious Engine 3-3.5 (Serious Sam HD and 3) are either compressed with DXT or uncompressed BGR/BGRA, but some of them have flag "packed". Here's 1024x256 texture exported with Serious Editor (official game tools):
Image
And here what I've got using uncompressed BGRA texture data:
Image
It looks like outlines of same picture but smaller and a whole bunch (also under every smaller copy are even smaller mip-maps but that's expected, they are stored in texture data), on picture I used black background for visibility, in reality there are same alpha channel. I've compared 2 different textures with same size and they have same texture data length so it's unlikely a compression? Also, even textures compressed with DXT can have this flag and will produce mess with just plain DXT decompression. Any ideas?

EDITED:
Never mind, figured it out by disassembling. In short - for BGR/BGRA data separated in blocks, first goes block of every pixel's B color, next G, R and A if has alpha. For DXT compressed almost same, but first goes block of first colors, then block of second colors and block of indices, and DXT3/5 another set of blocks

Post Reply