A reimplementation of Mario Kart Wii's physics engine in C++
Loading...
Searching...
No Matches
Kinoko::EGG::Decomp Namespace Reference

Functions

s32 DecodeSZS (const u8 *src, u8 *dst)
 Performs YAZ0 decompression on a given buffer.
constexpr bool CheckCompressed (const u8 *src)
 Checks if the given data is compressed, indicated by the first three bytes being set to Yaz.
constexpr s32 GetExpandSize (const u8 *src)

Function Documentation

◆ DecodeSZS()

s32 DecodeSZS ( const u8 * src,
u8 * dst )
0x80218C2C

Performs YAZ0 decompression on a given buffer.

Returns
The size of the decompressed data.

Definition at line 8 of file Decomp.cc.

Referenced by DecodeSZS(), DvdArchive::decompress(), and RawGhostFile::decompress().

◆ CheckCompressed()

bool CheckCompressed ( const u8 * src)
inlinenodiscardconstexpr0x802198F8

Checks if the given data is compressed, indicated by the first three bytes being set to Yaz.

Parameters
srcPointer to the data to check
Returns
true if the data is compressed, false otherwise

In the base game, this function normally returns an enum to account for other compression formats (ASH / ASR). We only need to handle Yaz0 compression for Kinoko.

Definition at line 14 of file Decomp.hh.

Referenced by CheckCompressed(), GetExpandSize(), DvdArchive::load(), and DvdArchive::load().

◆ GetExpandSize()

s32 GetExpandSize ( const u8 * src)
inlinenodiscardconstexpr0x8021997C