gvrtex
gvrtex is a Rust library for interfacing with the GVR texture format used in GameCube/Wii games, for example Sonic Riders. It's essentially the same as a regular TPL texture file (the official texture file format for GameCube/Wii), but with GVR headers instead. The image data in the file remains the same as it is for TPL files, so that the game console can read it.
More details on the GVR texture format can be found on the PuyoTools Wiki.
Examples
To encode an image into a GVR file (the supported image formats can be found here):
use TextureEncodeError;
use DataFormat;
use TextureEncoder;
To encode a GVR file with a quantized color palette (can be 4-bit indexed or 8-bit indexed):
use TextureEncodeError;
use ;
use TextureEncoder;
To decode a GVR file into the respective image file:
use TextureDecodeError;
use TextureDecoder;
Credits
- PuyoTools for the internal encoding and decoding algorithms, as well as information on the GVR file format.