[−][src]Struct oboe_sys::oboe_LatencyTuner
LatencyTuner can be used to dynamically tune the latency of an output stream. It adjusts the stream's bufferSize by monitoring the number of underruns.
This only affects the latency associated with the first level of buffering that is closest to the application. It does not affect low latency in the HAL, or touch latency in the UI.
Call tune() right before returning from your data callback function if using callbacks. Call tune() right before calling write() if using blocking writes.
If you want to see the ongoing results of this tuning process then call stream->getBufferSize() periodically.
Fields
mStream: *mut oboe_AudioStream
mState: oboe_LatencyTuner_State
mMaxBufferSize: i32
mPreviousXRuns: i32
mIdleCountDown: i32
mLatencyTriggerRequests: std_atomic
mLatencyTriggerResponses: std_atomic
Methods
impl oboe_LatencyTuner
[src]
pub unsafe fn tune(&mut self) -> oboe_Result
[src]
pub unsafe fn requestReset(&mut self)
[src]
pub unsafe fn isAtMaximumBufferSize(&mut self) -> bool
[src]
pub unsafe fn new(stream: *mut oboe_AudioStream) -> Self
[src]
pub unsafe fn new1(
stream: *mut oboe_AudioStream,
maximumBufferSize: i32
) -> Self
[src]
stream: *mut oboe_AudioStream,
maximumBufferSize: i32
) -> Self
Trait Implementations
impl Clone for oboe_LatencyTuner
[src]
fn clone(&self) -> oboe_LatencyTuner
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Copy for oboe_LatencyTuner
[src]
impl Debug for oboe_LatencyTuner
[src]
Auto Trait Implementations
impl RefUnwindSafe for oboe_LatencyTuner
impl !Send for oboe_LatencyTuner
impl !Sync for oboe_LatencyTuner
impl Unpin for oboe_LatencyTuner
impl UnwindSafe for oboe_LatencyTuner
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,