From ef512b5f33f3e2a782e05b8cdf308240d8b11565 Mon Sep 17 00:00:00 2001 From: Lucas Schwiderski Date: Fri, 21 Feb 2025 11:02:11 +0000 Subject: [PATCH] Update Reverse Engineering - Textures --- Reverse Engineering - Textures.-.md | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/Reverse Engineering - Textures.-.md b/Reverse Engineering - Textures.-.md index 95cf2a9..2e2b067 100644 --- a/Reverse Engineering - Textures.-.md +++ b/Reverse Engineering - Textures.-.md @@ -1,9 +1,22 @@ ## General -Textures are usually split into two data blobs: +There seem to be two ways that a texture can be stored in a bundle "data file" vs "stream file". -- Metadata and a small mipmap directly in the bundle -- All other mipmaps in stream files +- "data file": + - points to a file in `data/` without `.stream` extension + - size of the file in `data/` can range from 200 bytes to several MB -> no apparent correlation + - `external == true`, no data in bundle +- "stream file": + - points to a `.stream` file in `data/` + - data file size can range from 90 bytes to several MB + - always contains data in the bundle file, size ranging from 200 bytes to several KB + +In the case of stream files, the bundle will contain metadata (e.g. DDS headers) and a small mipmap, while the data file will contain the other mipmaps. + +Other things of note: + +- `BundleFileHeader.unknown_1` is always `1` +- textures can be duplicated across bundles ### Formats