Crates.io | pak |
lib.rs | pak |
version | 0.6.0 |
source | src |
created_at | 2017-09-19 03:52:09.175383 |
updated_at | 2024-09-23 09:45:24.604335 |
description | An easy-to-use data pak format for games. |
homepage | https://github.com/attackgoat/pak |
repository | https://github.com/attackgoat/pak |
max_upload_size | |
id | 32227 |
size | 285,277 |
.pak
Asset Crate.pak
Configuration FileEach asset package is "baked" from a configuration source file. Example:
Rust code
PakBuf::bake("game_art.toml", "game_art.pak")?;
game_art.toml
[content]
compression = 'snap'
[[content.group]]
assets = [
'bitmap/**/*.png',
'font/**/*.toml',
'model/**/*.toml',
'sound/**/*.ogg',
'music/*.mp3',
'ui/*.png',
]
Note:
Additional [[content.group]]
tables may be appended. All groups are added to the package and these
individual groups are not distinct entities in the runtime file.
[content]
Schema
Item | Description |
---|---|
compression | May be omitted, 'snap' or 'x' |
Example:
[model]
src = "some_file.gltf"
[model]
Schema
Item | Description |
---|
src
| File path to the .gltf
or .glb
model file. May be relative to the [model]
TOML file or absolute where the root is the same folder as the [content]
TOML file.
Run tests with all features in order to include the baking code:
cargo test --all-features