#[repr(C)]pub struct retro_game_info_ext {
pub full_path: *const c_char,
pub archive_path: *const c_char,
pub archive_file: *const c_char,
pub dir: *const c_char,
pub name: *const c_char,
pub ext: *const c_char,
pub meta: *const c_char,
pub data: *const c_void,
pub size: usize,
pub file_in_archive: bool,
pub persistent_data: bool,
}
Expand description
Similar to retro_game_info, but provides extended information about the source content file and game memory buffer status. And array of retro_game_info_ext is returned by RETRO_ENVIRONMENT_GET_GAME_INFO_EXT NOTE: In the following descriptions, references to retro_load_game() may be replaced with retro_load_game_special()
Fields§
§full_path: *const c_char
- If file_in_archive is false, contains a valid path to an existent content file (UTF-8 encoded)
- If file_in_archive is true, may be NULL
archive_path: *const c_char
- If file_in_archive is false, may be NULL
- If file_in_archive is true, contains a valid path to an existent compressed file inside which the content file is located (UTF-8 encoded)
archive_file: *const c_char
- If file_in_archive is false, may be NULL
- If file_in_archive is true, contain a valid path
to an existent content file inside the compressed
file referred to by archive_path (UTF-8 encoded)
e.g. for a compressed file ‘/path/to/foo.zip’
containing ‘bar.sfc’
archive_path will be ‘/path/to/foo.zip’ archive_file will be ‘bar.sfc’
dir: *const c_char
- If file_in_archive is false, contains a valid path to the directory in which the content file exists (UTF-8 encoded)
- If file_in_archive is true, contains a valid path to the directory in which the compressed file (containing the content file) exists (UTF-8 encoded)
name: *const c_char
Contains the canonical name/ID of the content file (UTF-8 encoded). Intended for use when identifying ‘complementary’ content named after the loaded file - i.e. companion data of a different format (a CD image required by a ROM), texture packs, internally handled save files, etc.
- If file_in_archive is false, contains the basename of the content file, without extension
- If file_in_archive is true, then string is
implementation specific. A frontend may choose to
set a name value of:
EITHER
- the basename of the compressed file (containing the content file), without extension OR
- the basename of the content file inside the compressed file, without extension RetroArch sets the ‘name’ value according to (1). A frontend that supports routine loading of content from archives containing multiple unrelated content files may set the ‘name’ value according to (2).
ext: *const c_char
- If file_in_archive is false, contains the extension of the content file in lower case format
- If file_in_archive is true, contains the extension of the content file inside the compressed file, in lower case format
meta: *const c_char
String of implementation specific meta-data.
data: *const c_void
Memory buffer of loaded game content. Will be NULL: IF
- retro_system_info::need_fullpath is true and retro_system_content_info_override::need_fullpath is unset OR
- retro_system_content_info_override::need_fullpath is true
size: usize
Size of game content memory buffer, in bytes
file_in_archive: bool
True if loaded content file is inside a compressed archive
persistent_data: bool
- If data is NULL, value is unset/ignored
- If data is non-NULL:
- If persistent_data is false, data and size are valid only until retro_load_game() returns
- If persistent_data is true, data and size are are valid until retro_deinit() returns
Trait Implementations§
Source§impl Clone for retro_game_info_ext
impl Clone for retro_game_info_ext
Source§fn clone(&self) -> retro_game_info_ext
fn clone(&self) -> retro_game_info_ext
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
source
. Read more