pub struct GpuCounterConfig {
pub counter_period_ns: Option<u64>,
pub counter_ids: Vec<u32>,
pub counter_names: Vec<String>,
pub fix_gpu_clock: Option<bool>,
pub instrumented_sampling_mode: Option<InstrumentedSamplingMode>,
}Fields§
§counter_period_ns: Option<u64>Desired sampling interval for counters.
counter_ids: Vec<u32>Selects which counters to sample. Use either counter_ids or counter_names, not both. Counter IDs and names correspond to the ones described in GpuCounterSpec in the data source descriptor.
List of counter IDs to be sampled.
counter_names: Vec<String>List of counter names to be sampled. Requires producer support; check GpuCounterDescriptor.supports_counter_names in the data source descriptor. Glob patterns may be used to match multiple counters by name; check GpuCounterDescriptor.supports_counter_name_globs for support.
fix_gpu_clock: Option<bool>Fix gpu clock rate during trace session.
instrumented_sampling_mode: Option<InstrumentedSamplingMode>Sample counters by instrumenting command buffers.
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 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
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
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
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
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,
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self.