| | | Table of contents - Current version is
0.0 - File extension is
.ptf - Data is little endian
- LZ4F is used for compression
| Type | Description | | Header | File header | | Data | Image data | | Type | Value | Description | char[3] | {'P', 'T', 'F'} | Header magic | u8 | 0 | Major version | u8 | Info | Info | u8 | Resolution | Resolution | Info | Bits (LSB to MSB) | Value | Description | | 0..1 | Pixel format | Pixel data format | | 2..3 | 0 | Reserved | | 4..7 | Flags | Flags | Flags | Bits (LSB to MSB) | Value | Description | | 0..3 | 0 | Reserved | | Name | Value | PTF_FRMT_I | 0 | PTF_FRMT_IA | 1 | PTF_FRMT_RGB | 2 | PTF_FRMT_RGBA | 3 | Resolution | Bits (LSB to MSB) | Description | | 0..3 | Width (2^n) | | 4..7 | Height (2^n) | Data I pixel | Type | Description | u8 | Intensity | IA pixel | Type | Description | u8[2] | Intensity and alpha | RGB pixel | Type | Description | u8[3] | Red, green, and blue | RGBA pixel | Type | Description | u8[4] | Red, green, blue, and alpha | | |