#[repr(C)]
pub struct playdate_sound_instrument {
Show 13 fields pub newInstrument: Option<unsafe extern "C" fn() -> *mut PDSynthInstrument>, pub freeInstrument: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument)>, pub addVoice: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, synth: *mut PDSynth, rangeStart: MIDINote, rangeEnd: MIDINote, transpose: f32) -> c_int>, pub playNote: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, frequency: f32, vel: f32, len: f32, when: u32) -> *mut PDSynth>, pub playMIDINote: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, note: MIDINote, vel: f32, len: f32, when: u32) -> *mut PDSynth>, pub setPitchBend: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, bend: f32)>, pub setPitchBendRange: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, halfSteps: f32)>, pub setTranspose: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, halfSteps: f32)>, pub noteOff: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, note: MIDINote, when: u32)>, pub allNotesOff: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, when: u32)>, pub setVolume: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, left: f32, right: f32)>, pub getVolume: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, left: *mut f32, right: *mut f32)>, pub activeVoiceCount: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument) -> c_int>,
}

Fields

newInstrument: Option<unsafe extern "C" fn() -> *mut PDSynthInstrument>freeInstrument: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument)>addVoice: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, synth: *mut PDSynth, rangeStart: MIDINote, rangeEnd: MIDINote, transpose: f32) -> c_int>playNote: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, frequency: f32, vel: f32, len: f32, when: u32) -> *mut PDSynth>playMIDINote: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, note: MIDINote, vel: f32, len: f32, when: u32) -> *mut PDSynth>setPitchBend: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, bend: f32)>setPitchBendRange: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, halfSteps: f32)>setTranspose: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, halfSteps: f32)>noteOff: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, note: MIDINote, when: u32)>allNotesOff: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, when: u32)>setVolume: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, left: f32, right: f32)>getVolume: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument, left: *mut f32, right: *mut f32)>activeVoiceCount: Option<unsafe extern "C" fn(inst: *mut PDSynthInstrument) -> c_int>

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.