LibT2FS 0.1
C API for accessing TEngine data in memory.
Loading...
Searching...
No Matches
s_t2fsInput Struct Reference

object to handle input reading More...

#include <t2fs.h>

Data Fields

FILE * fp
 For reading data from file.
long fileSize
 Total filesize.
uint8_t * buf
 Decompressed buffer.
uint32_t bufSize
 Decompressed buffer size.
uint32_t bufOffset
 Current offset mimicking FILE.
t2fs_read_callbackread
 The function used to read, this will depend on whether we are reading from file or from a decompressed buffer.
t2fs_seek_callbackseek
 The function used to seek, this will depend on whether we are reading from file or from a decompressed buffer.
t2fs_read_value_callbackreadValue
 Special function to read values for standard types, use case for this is when we handle BE files, we can set it to a function that does the endianess swapping for us. Should only be used for a container size of 2 or 4 bytes, see e_t2fsReadSize. This was added in order to support BE N64 data ripped from N64 roms.

Detailed Description

object to handle input reading

Field Documentation

◆ fp

FILE* s_t2fsInput::fp

For reading data from file.

◆ fileSize

long s_t2fsInput::fileSize

Total filesize.

◆ buf

uint8_t* s_t2fsInput::buf

Decompressed buffer.

◆ bufSize

uint32_t s_t2fsInput::bufSize

Decompressed buffer size.

◆ bufOffset

uint32_t s_t2fsInput::bufOffset

Current offset mimicking FILE.

◆ read

t2fs_read_callback* s_t2fsInput::read

The function used to read, this will depend on whether we are reading from file or from a decompressed buffer.

◆ seek

t2fs_seek_callback* s_t2fsInput::seek

The function used to seek, this will depend on whether we are reading from file or from a decompressed buffer.

◆ readValue

t2fs_read_value_callback* s_t2fsInput::readValue

Special function to read values for standard types, use case for this is when we handle BE files, we can set it to a function that does the endianess swapping for us. Should only be used for a container size of 2 or 4 bytes, see e_t2fsReadSize. This was added in order to support BE N64 data ripped from N64 roms.


The documentation for this struct was generated from the following file: