Skip to content

rc_console_memory_regions

Jamiras edited this page Sep 7, 2020 · 1 revision

Gets the memory regions expected by the achievement code for the specified console.

Syntax

const rc_memory_regions_t* rc_console_memory_regions(
    int console_id
);

Parameters

console_id

Specifies the console for which memory region data should be retrieved.

For a list of known consoles, see rconsoles.h. Note that not all consoles identified in the enum currently define memory regions.

Return value

The return value is a pointer to a rc_memory_regions_t structure. If the console is not supported, the num_regions member of the structure will be zero.

If the console is supported, the num_regions member will specify the size of the array in the region member. Each region will provide a start and end address (as identified by the achievement code) and some additional information to map those addresses to the memory managed by the emulator. These mappings should be used either to dynamically look up memory or to define a static mapping when implementing an rc_peek_t function.

Remarks

This function is primarily intended for emulators that support multiple consoles generically. For standalone emulators that only support one or a handful of systems, the return value can be examined to aid in the implementation of a static memory accessor.

Minimum version: 9.0.0

See also

rc_console_name

rc_runtime_do_frame

rcheevos

rc_client

Integration guide

client

user

game

processing

rc_client_raintegration

Integration guide

rc_runtime

rhash

rapi

common

user

runtime

info

Clone this wiki locally