pub(super) struct PhaseTimer {
buffer: Retained<ProtocolObject<dyn MTLCounterSampleBuffer>>,
count: usize,
cpu: RefCell<Vec<CpuWindow>>,
timebase: MachTimebase,
}Fields§
§buffer: Retained<ProtocolObject<dyn MTLCounterSampleBuffer>>§count: usize§cpu: RefCell<Vec<CpuWindow>>§timebase: MachTimebaseImplementations§
Source§impl PhaseTimer
impl PhaseTimer
pub(super) fn initialize( ctx: &MetalContext, slots: usize, enabled: bool, ) -> (Option<Self>, GpuTiming)
fn initialization_result( result: Result<Option<Self>>, ) -> (Option<Self>, GpuTiming)
pub(super) fn new(ctx: &MetalContext, slots: usize) -> Result<Option<Self>>
fn encoder( &self, cb: &ProtocolObject<dyn MTLCommandBuffer>, start: Option<usize>, end: usize, ) -> Result<Retained<ProtocolObject<dyn MTLComputeCommandEncoder>>>
fn timestamps(&self) -> Option<Vec<u64>>
Auto Trait Implementations§
impl !Freeze for PhaseTimer
impl !RefUnwindSafe for PhaseTimer
impl !Send for PhaseTimer
impl !Sync for PhaseTimer
impl !UnwindSafe for PhaseTimer
impl Unpin for PhaseTimer
impl UnsafeUnpin for PhaseTimer
Blanket Implementations§
impl<T> AutoreleaseSafe for Twhere
T: ?Sized,
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<T> ErasedDestructor for Twhere
T: 'static,
§impl<T> Identity for Twhere
T: ?Sized,
impl<T> Identity for Twhere
T: ?Sized,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more