Skip to content

Nenkai/GraniteTextureReader

Repository files navigation

GraniteTextureReader

Texture Reader/Extractor for Granite SDK files (.gts/.gtp). This tool was primarly made with Granblue Fantasy: Relink in mind, but should also support extracting from Unity games using Streaming Virtual Texturing.

The Granite SDK has long been acquired by Unity and for the most part shelved (main page on the Unity site is gone), so updates to the format are unlikely.

It is known to be used in:

  • Granblue Fantasy: Relink (proprietary, long development cycle, likely acquired Granite licensing before Unity acquired it)
  • Baldur's Gate 3 (same as above)
  • Conan Exiles (Unreal)
  • Mount & Blade II: Bannerlord (Unreal)
  • The very few Unity games that opt-in to use Streaming Virtual Texturing, which has been marked as experimental for years and at this point abandoned yet still available

Features

  • Extraction of all textures within a Granite SDK tile set (.gts)
  • Extracting specific textures within a tile set
  • Downgrading a tile set from version 6 to 5 for use within the Granite Tile Set viewer
  • Extracting project files out of tile set files (if the tile set was not built as release/unstripped)

Important

Only version 6 .gts files are currently supported. (Version can be viewed at 0x04 in the .gts files)

Warning

This project is currently in stand-by and will not currently receive updates unless contributions are made (which are welcome).

Usage

Get the latest version in Releases.

To extract a tile set in its entirety, run the command with:

GraniteTextureReader extract-all --tileset <path_to_gts_file> [--layer <layer>]
  • Replace <path_to_gts_file> with the path to the GTS file
  • Optionally also provide --layer to extract a specific tile set layer. By default all are extracted. Different layers are intended for different types of textures, so a simple example would be texture layer 0 being Albedo map, 1 being Normal map. Up to 3.

More commands are available by just running the command and reading the command/verb listing.

Documentation

File format documentation/010 Editor Template is available here.

The official website used to sit at https://graphinesoftware.com/

Other libraries that can handle creating such files:

Building

Requires .NET 9.0 (VS2022).

About

Granite SDK Texture Extractor (.gtp/gts).

Topics

Resources

License

Stars

Watchers

Forks

Sponsor this project

Packages

No packages published

Contributors 2

  •  
  •  

Languages