Struct rustzx_core::Emulator [−][src]
pub struct Emulator<H: Host> { /* fields omitted */ }
Expand description
Represents main Emulator structure
Implementations
impl<H: Host> Emulator<H>
[src]
impl<H: Host> Emulator<H>
[src]pub fn new(settings: RustzxSettings, context: H::Context) -> Result<Self>
[src]
pub fn new(settings: RustzxSettings, context: H::Context) -> Result<Self>
[src]pub fn set_speed(&mut self, new_speed: EmulationSpeed)
[src]
pub fn set_speed(&mut self, new_speed: EmulationSpeed)
[src]changes emulation speed
pub fn set_fast_load(&mut self, value: bool)
[src]
pub fn set_fast_load(&mut self, value: bool)
[src]changes fast loading flag
pub fn load_snapshot<A>(&mut self, snapshot: Snapshot<A>) -> Result<()> where
A: LoadableAsset + SeekableAsset,
[src]
A: LoadableAsset + SeekableAsset,
pub fn save_snapshot<R>(&mut self, recorder: SnapshotRecorder<R>) -> Result<()> where
R: DataRecorder,
[src]
R: DataRecorder,
pub fn load_tape(&mut self, tape: Tape<H::TapeAsset>) -> Result<()>
[src]
pub fn load_rom(&mut self, rom: H::RomSet) -> Result<()>
[src]
pub fn play_tape(&mut self)
[src]
pub fn stop_tape(&mut self)
[src]
pub fn screen_buffer(&self) -> &H::FrameBuffer
[src]
pub fn border_color(&self) -> ZXColor
[src]
pub fn send_key(&mut self, key: ZXKey, pressed: bool)
[src]
pub fn send_compound_key(&mut self, key: CompoundKey, pressed: bool)
[src]
pub fn send_kempston_key(&mut self, key: KempstonKey, pressed: bool)
[src]
pub fn send_sinclair_key(
&mut self,
num: SinclairJoyNum,
key: SinclairKey,
pressed: bool
)
[src]
&mut self,
num: SinclairJoyNum,
key: SinclairKey,
pressed: bool
)
pub fn send_mouse_button(&mut self, button: KempstonMouseButton, pressed: bool)
[src]
pub fn send_mouse_wheel(&mut self, dir: KempstonMouseWheelDirection)
[src]
pub fn send_mouse_pos(&mut self, x: i8, y: i8)
[src]
Auto Trait Implementations
impl<H> RefUnwindSafe for Emulator<H> where
<H as Host>::FrameBuffer: RefUnwindSafe,
<H as Host>::TapeAsset: RefUnwindSafe,
<H as Host>::FrameBuffer: RefUnwindSafe,
<H as Host>::TapeAsset: RefUnwindSafe,
impl<H> Send for Emulator<H> where
<H as Host>::FrameBuffer: Send,
<H as Host>::TapeAsset: Send,
<H as Host>::FrameBuffer: Send,
<H as Host>::TapeAsset: Send,
impl<H> Sync for Emulator<H> where
<H as Host>::FrameBuffer: Sync,
<H as Host>::TapeAsset: Sync,
<H as Host>::FrameBuffer: Sync,
<H as Host>::TapeAsset: Sync,
impl<H> Unpin for Emulator<H> where
<H as Host>::FrameBuffer: Unpin,
<H as Host>::TapeAsset: Unpin,
<H as Host>::FrameBuffer: Unpin,
<H as Host>::TapeAsset: Unpin,
impl<H> UnwindSafe for Emulator<H> where
<H as Host>::FrameBuffer: UnwindSafe,
<H as Host>::TapeAsset: UnwindSafe,
<H as Host>::FrameBuffer: UnwindSafe,
<H as Host>::TapeAsset: UnwindSafe,