pub struct GsuMem<'a> {
pub rom: &'a [u8],
pub rom_mask: u32,
pub ram: &'a mut [u8],
pub ram_mask: u32,
}Expand description
The Game Pak ROM/RAM the GSU reads and plots into, with the GSU-internal 24-bit decode.
The board constructs this each run, borrowing its ROM (shared, read-only) and its Game Pak
RAM (the plot target). The address map is the GSU’s own view (ares SuperFX::read/write):
banks $00-$3F fold LoROM-style, $40-$5F are linear ROM, $70-$71 are the RAM bitmap.
Fields§
§rom: &'a [u8]Game Pak ROM image (already mirror-rounded to a power-of-two rom_mask + 1).
rom_mask: u32rom.len().next_power_of_two() - 1 (ares romSizeRound(rom.size()) - 1).
ram: &'a mut [u8]Game Pak RAM (the GSU plot bitmap), ram_mask + 1 bytes.
ram_mask: u32ram.len() - 1 (RAM is always a power of two).
Auto Trait Implementations§
impl<'a> Freeze for GsuMem<'a>
impl<'a> RefUnwindSafe for GsuMem<'a>
impl<'a> Send for GsuMem<'a>
impl<'a> Sync for GsuMem<'a>
impl<'a> Unpin for GsuMem<'a>
impl<'a> UnsafeUnpin for GsuMem<'a>
impl<'a> !UnwindSafe for GsuMem<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more