pub struct GpuCounterConfig {
pub counter_period_ns: Option<u64>,
pub counter_ids: Vec<u32>,
pub instrumented_sampling: Option<bool>,
pub fix_gpu_clock: Option<bool>,
}
Fields§
§counter_period_ns: Option<u64>
Desired sampling interval for counters.
counter_ids: Vec<u32>
List of counters to be sampled. Counter IDs correspond to the ones described in GpuCounterSpec in the data source descriptor.
instrumented_sampling: Option<bool>
Sample counters by instrumenting command buffers.
fix_gpu_clock: Option<bool>
Fix gpu clock rate during trace session.
Implementations§
Source§impl GpuCounterConfig
impl GpuCounterConfig
Sourcepub fn counter_period_ns(&self) -> u64
pub fn counter_period_ns(&self) -> u64
Returns the value of counter_period_ns
, or the default value if counter_period_ns
is unset.
Sourcepub fn instrumented_sampling(&self) -> bool
pub fn instrumented_sampling(&self) -> bool
Returns the value of instrumented_sampling
, or the default value if instrumented_sampling
is unset.
Sourcepub fn fix_gpu_clock(&self) -> bool
pub fn fix_gpu_clock(&self) -> bool
Returns the value of fix_gpu_clock
, or the default value if fix_gpu_clock
is unset.
Trait Implementations§
Source§impl Clone for GpuCounterConfig
impl Clone for GpuCounterConfig
Source§fn clone(&self) -> GpuCounterConfig
fn clone(&self) -> GpuCounterConfig
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for GpuCounterConfig
impl Debug for GpuCounterConfig
Source§impl Default for GpuCounterConfig
impl Default for GpuCounterConfig
Source§impl Message for GpuCounterConfig
impl Message for GpuCounterConfig
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Returns the encoded length of the message without a length delimiter.
Source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
Encodes the message to a buffer. Read more
Source§fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
Encodes the message to a newly allocated buffer.
Source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
Encodes the message with a length-delimiter to a buffer. Read more
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
Encodes the message with a length-delimiter to a newly allocated buffer.
Source§fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
Decodes an instance of the message from a buffer. Read more
Source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
Decodes a length-delimited instance of the message from the buffer.
Source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
Decodes an instance of the message from a buffer, and merges it into
self
. Read moreSource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
Decodes a length-delimited instance of the message from buffer, and
merges it into
self
.Source§impl PartialEq for GpuCounterConfig
impl PartialEq for GpuCounterConfig
impl StructuralPartialEq for GpuCounterConfig
Auto Trait Implementations§
impl Freeze for GpuCounterConfig
impl RefUnwindSafe for GpuCounterConfig
impl Send for GpuCounterConfig
impl Sync for GpuCounterConfig
impl Unpin for GpuCounterConfig
impl UnwindSafe for GpuCounterConfig
Blanket Implementations§
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)