Struct dbsdk_rs::audio::AudioSample
source · [−]Fields
handle: i32
samplerate: i32
Implementations
sourceimpl AudioSample
impl AudioSample
sourcepub fn create_s8(pcm_data: &[i8], samplerate: i32) -> Result<AudioSample, ()>
pub fn create_s8(pcm_data: &[i8], samplerate: i32) -> Result<AudioSample, ()>
Create a new signed 8-bit PCM audio sample
sourcepub fn create_s16(pcm_data: &[i16], samplerate: i32) -> Result<AudioSample, ()>
pub fn create_s16(pcm_data: &[i16], samplerate: i32) -> Result<AudioSample, ()>
Create a new signed 16-bit PCM audio sample
sourcepub fn create_adpcm(
adpcm_data: &[u8],
chunk_size: i32,
samplerate: i32
) -> Result<AudioSample, ()>
pub fn create_adpcm(
adpcm_data: &[u8],
chunk_size: i32,
samplerate: i32
) -> Result<AudioSample, ()>
Create a new IMA ADPCM encoded audio sample
Trait Implementations
sourceimpl Clone for AudioSample
impl Clone for AudioSample
sourcefn clone(&self) -> AudioSample
fn clone(&self) -> AudioSample
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations
impl RefUnwindSafe for AudioSample
impl Send for AudioSample
impl Sync for AudioSample
impl Unpin for AudioSample
impl UnwindSafe for AudioSample
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more