KallistiOS git master
Independent SDK for the Sega Dreamcast
Loading...
Searching...
No Matches

API for Managing VMU File Headers More...

Topics

 Eyecatch Types
 Values for various VMU eyecatch formats
 

Files

file  vmu_pkg.h
 VMU Packaging functionality.
 

Data Structures

struct  vmu_pkg_t
 VMU Package type. More...
 
struct  vmu_hdr_t
 Final VMU package type. More...
 

Functions

int vmu_pkg_build (vmu_pkg_t *src, uint8 **dst, int *dst_size)
 Convert a vmu_pkg_t into an array of uint8s.
 
int vmu_pkg_parse (uint8 *data, vmu_pkg_t *pkg)
 Parse an array of uint8s into a vmu_pkg_t.
 

Detailed Description

API for Managing VMU File Headers

This API is provided as a utility for easy management of VMS file headers. These headers must be present on every file saved within the VMU's filesystem for both the Dreamcast and VMU's BIOS to detect them properly.

Function Documentation

◆ vmu_pkg_build()

int vmu_pkg_build ( vmu_pkg_t * src,
uint8 ** dst,
int * dst_size )

Convert a vmu_pkg_t into an array of uint8s.

This function converts a vmu_pkg_t structure into an array of uint8's which may be written to a VMU file via fs_vmu, or whatever.

Parameters
srcThe vmu_pkg_t to convert.
dstThe buffer (will be allocated for you).
dst_sizeThe size of the output.
Returns
0 on success, <0 on failure.

◆ vmu_pkg_parse()

int vmu_pkg_parse ( uint8 * data,
vmu_pkg_t * pkg )

Parse an array of uint8s into a vmu_pkg_t.

This function does the opposite of vmu_pkg_build and is used to parse VMU files read in.

Parameters
dataThe buffer to parse.
pkgWhere to store the vmu_pkg_t.
Return values
-1On invalid CRC in the data.
0On success.