benilla-re systems structs docs

s_textureFileBytesUsed

global · gx

Address
0xb05d18 · 4 bytes, up to 0xb05d1b
Type
uint32_t
Meaning
Holds the bytes of the static file area already given to async texture records
Confidence
verified, proof one
Finding
gx/textures#texture-file-creation

Finding: Texture file creation in gx: textures

0x449610(path, format, loose) opens path split by 0x449590 with .blp (0x83524c) appended through SFile::OpenEx(0, name, loose != 0, &handle) (storm/mount#loose-files), returns 0 on failure, else allocates a CTexture, sets bit 0x2 of +0x110 for loose, copies the name, stores format at +0x118 and 0 at +0x120, and takes an async record from 0x4438b0: record +0 the file, +8 its size, +0xc the texture, +0x10 the completion callback 0x4497f0. When the file's size fits in what remains of 2 MiB (counter 0xb05d18) the record's buffer is the next slice of the static area at 0x905be4 and 0x443ae0 queues the read; otherwise the record joins the waiting list. 0x44a310 does the same for a name with its extension, callback 0x44a500.

The derivation is in the doc.