Expand description
§Plastic NES Core
This is the core of the Plastic NES emulator. It contains the CPU, PPU, APU, and other components and can be used standalone to run/emulate NES games if you want to handle your own input/output.
A very simple example of how to use this crate:
use plastic_core::NES;
fn main() {
let mut nes = NES::new("path/to/rom-file.nes").unwrap();
loop {
nes.clock_for_frame();
let pixel_buffer = nes.pixel_buffer();
display(&pixel_buffer);
let audio_buffer = nes.audio_buffer();
play_audio(&audio_buffer);
}
}In the
Modules§
- cpu
- Structures used when interacting with the CPU, see also
NES::clock - nes_
audio - Helper variables related to handling audio buffers from the emulator
- nes_
display - Helper variables related to handling pixel buffers from the emulator
Structs§
- NES
- The main
NESemulator struct, containing all components and what is actually doing the emulation.
Enums§
- Cartridge
Error - Error happening when loading a NES cartridge.
- NESKey
- Represents the keys on an NES controller.
- Save
Error - Error happening when saving/loading a state