Trait gstreamer::subclass::prelude::ClockImpl

source ·
pub trait ClockImpl: ClockImplExt + GstObjectImpl + Send + Sync {
    // Provided methods
    fn change_resolution(
        &self,
        old_resolution: ClockTime,
        new_resolution: ClockTime,
    ) -> ClockTime { ... }
    fn resolution(&self) -> ClockTime { ... }
    fn internal_time(&self) -> ClockTime { ... }
    fn wait(
        &self,
        id: &ClockId,
    ) -> (Result<ClockSuccess, ClockError>, ClockTimeDiff) { ... }
    fn wait_async(&self, id: &ClockId) -> Result<ClockSuccess, ClockError> { ... }
    fn unschedule(&self, id: &ClockId) { ... }
}

Provided Methods§

source

fn change_resolution( &self, old_resolution: ClockTime, new_resolution: ClockTime, ) -> ClockTime

Change the resolution of the clock. Not all values might be acceptable.

§old_resolution

the previous resolution

§new_resolution

the new resolution

§Returns

the new resolution

source

fn resolution(&self) -> ClockTime

Gets the accuracy of the clock. The accuracy of the clock is the granularity of the values returned by ClockExt::time().

§Returns

the resolution of the clock in units of GstClockTime.

source

fn internal_time(&self) -> ClockTime

Gets the current internal time of the given clock. The time is returned unadjusted for the offset and the rate.

§Returns

the internal time of the clock. Or GST_CLOCK_TIME_NONE when given invalid input.

source

fn wait( &self, id: &ClockId, ) -> (Result<ClockSuccess, ClockError>, ClockTimeDiff)

Perform a blocking wait on the given GstClockEntry and return the jitter.

§entry

the entry to wait on

§Returns

the result of the blocking wait. ClockReturn::Early will be returned if the current clock time is past the time of id, ClockReturn::Ok if id was scheduled in time. ClockReturn::Unscheduled if id was unscheduled with gst_clock_id_unschedule().

§jitter

a pointer that will contain the jitter

source

fn wait_async(&self, id: &ClockId) -> Result<ClockSuccess, ClockError>

Perform an asynchronous wait on the given GstClockEntry.

§entry

the entry to wait on

§Returns

the result of the non blocking wait.

source

fn unschedule(&self, id: &ClockId)

Unblock a blocking or async wait operation.

§entry

the entry to unschedule

Object Safety§

This trait is not object safe.

Implementors§