Struct webrender::renderer::DebugFlags
source · #[repr(C)]pub struct DebugFlags(pub(crate) u32);
Expand description
Flags to enable/disable various builtin debugging tools.
Tuple Fields§
§0: u32
Implementations§
source§impl DebugFlags
impl DebugFlags
sourcepub const PROFILER_DBG: DebugFlags = _
pub const PROFILER_DBG: DebugFlags = _
Display the frame profiler on screen.
sourcepub const RENDER_TARGET_DBG: DebugFlags = _
pub const RENDER_TARGET_DBG: DebugFlags = _
Display intermediate render targets on screen.
sourcepub const TEXTURE_CACHE_DBG: DebugFlags = _
pub const TEXTURE_CACHE_DBG: DebugFlags = _
Display all texture cache pages on screen.
sourcepub const GPU_TIME_QUERIES: DebugFlags = _
pub const GPU_TIME_QUERIES: DebugFlags = _
Display GPU timing results.
sourcepub const GPU_SAMPLE_QUERIES: DebugFlags = _
pub const GPU_SAMPLE_QUERIES: DebugFlags = _
Query the number of pixels that pass the depth test divided and show it in the profiler as a percentage of the number of pixels in the screen (window width times height).
sourcepub const DISABLE_BATCHING: DebugFlags = _
pub const DISABLE_BATCHING: DebugFlags = _
Render each quad with their own draw call.
Terrible for performance but can help with understanding the drawing order when inspecting renderdoc or apitrace recordings.
sourcepub const EPOCHS: DebugFlags = _
pub const EPOCHS: DebugFlags = _
Display the pipeline epochs.
sourcepub const ECHO_DRIVER_MESSAGES: DebugFlags = _
pub const ECHO_DRIVER_MESSAGES: DebugFlags = _
Print driver messages to stdout.
sourcepub const SHOW_OVERDRAW: DebugFlags = _
pub const SHOW_OVERDRAW: DebugFlags = _
Show an overlay displaying overdraw amount.
sourcepub const GPU_CACHE_DBG: DebugFlags = _
pub const GPU_CACHE_DBG: DebugFlags = _
Display the contents of GPU cache.
sourcepub const TEXTURE_CACHE_DBG_CLEAR_EVICTED: DebugFlags = _
pub const TEXTURE_CACHE_DBG_CLEAR_EVICTED: DebugFlags = _
Clear evicted parts of the texture cache for debugging purposes.
sourcepub const PICTURE_CACHING_DBG: DebugFlags = _
pub const PICTURE_CACHING_DBG: DebugFlags = _
Show picture caching debug overlay
sourcepub const PRIMITIVE_DBG: DebugFlags = _
pub const PRIMITIVE_DBG: DebugFlags = _
Highlight all primitives with colors based on kind.
sourcepub const ZOOM_DBG: DebugFlags = _
pub const ZOOM_DBG: DebugFlags = _
Draw a zoom widget showing part of the framebuffer zoomed in.
sourcepub const SMALL_SCREEN: DebugFlags = _
pub const SMALL_SCREEN: DebugFlags = _
Scale the debug renderer down for a smaller screen. This will disrupt any mapping between debug display items and page content, so shouldn’t be used with overlays like the picture caching or primitive display.
sourcepub const DISABLE_OPAQUE_PASS: DebugFlags = _
pub const DISABLE_OPAQUE_PASS: DebugFlags = _
Disable various bits of the WebRender pipeline, to help narrow down where slowness might be coming from.
sourcepub const DISABLE_ALPHA_PASS: DebugFlags = _
pub const DISABLE_ALPHA_PASS: DebugFlags = _
sourcepub const DISABLE_CLIP_MASKS: DebugFlags = _
pub const DISABLE_CLIP_MASKS: DebugFlags = _
sourcepub const DISABLE_TEXT_PRIMS: DebugFlags = _
pub const DISABLE_TEXT_PRIMS: DebugFlags = _
sourcepub const DISABLE_GRADIENT_PRIMS: DebugFlags = _
pub const DISABLE_GRADIENT_PRIMS: DebugFlags = _
sourcepub const OBSCURE_IMAGES: DebugFlags = _
pub const OBSCURE_IMAGES: DebugFlags = _
sourcepub const GLYPH_FLASHING: DebugFlags = _
pub const GLYPH_FLASHING: DebugFlags = _
Taint the transparent area of the glyphs with a random opacity to easily see when glyphs are re-rasterized.
sourcepub const SMART_PROFILER: DebugFlags = _
pub const SMART_PROFILER: DebugFlags = _
The profiler only displays information that is out of the ordinary.
sourcepub const INVALIDATION_DBG: DebugFlags = _
pub const INVALIDATION_DBG: DebugFlags = _
If set, dump picture cache invalidation debug to console.
sourcepub const PROFILER_CAPTURE: DebugFlags = _
pub const PROFILER_CAPTURE: DebugFlags = _
Collect and dump profiler statistics to captures.
sourcepub const FORCE_PICTURE_INVALIDATION: DebugFlags = _
pub const FORCE_PICTURE_INVALIDATION: DebugFlags = _
Invalidate picture tiles every frames (useful when inspecting GPU work in external tools).
sourcepub const WINDOW_VISIBILITY_DBG: DebugFlags = _
pub const WINDOW_VISIBILITY_DBG: DebugFlags = _
Display window visibility on screen.
sourcepub const RESTRICT_BLOB_SIZE: DebugFlags = _
pub const RESTRICT_BLOB_SIZE: DebugFlags = _
Render large blobs with at a smaller size (incorrectly). This is a temporary workaround for fuzzing.
sourcepub const SURFACE_PROMOTION_LOGGING: DebugFlags = _
pub const SURFACE_PROMOTION_LOGGING: DebugFlags = _
Enable surface promotion logging.
source§impl DebugFlags
impl DebugFlags
sourcepub const fn empty() -> DebugFlags
pub const fn empty() -> DebugFlags
Get a flags value with all bits unset.
sourcepub const fn all() -> DebugFlags
pub const fn all() -> DebugFlags
Get a flags value with all known bits set.
sourcepub const fn bits(&self) -> u32
pub const fn bits(&self) -> u32
Get the underlying bits value.
The returned value is exactly the bits set in this flags value.
sourcepub const fn from_bits(bits: u32) -> Option<DebugFlags>
pub const fn from_bits(bits: u32) -> Option<DebugFlags>
Convert from a bits value.
This method will return None
if any unknown bits are set.
sourcepub const fn from_bits_truncate(bits: u32) -> DebugFlags
pub const fn from_bits_truncate(bits: u32) -> DebugFlags
Convert from a bits value, unsetting any unknown bits.
sourcepub const fn from_bits_retain(bits: u32) -> DebugFlags
pub const fn from_bits_retain(bits: u32) -> DebugFlags
Convert from a bits value exactly.
sourcepub fn from_name(name: &str) -> Option<DebugFlags>
pub fn from_name(name: &str) -> Option<DebugFlags>
Get a flags value with the bits of a flag with the given name set.
This method will return None
if name
is empty or doesn’t
correspond to any named flag.
sourcepub const fn intersects(&self, other: DebugFlags) -> bool
pub const fn intersects(&self, other: DebugFlags) -> bool
Whether any set bits in a source flags value are also set in a target flags value.
sourcepub const fn contains(&self, other: DebugFlags) -> bool
pub const fn contains(&self, other: DebugFlags) -> bool
Whether all set bits in a source flags value are also set in a target flags value.
sourcepub fn insert(&mut self, other: DebugFlags)
pub fn insert(&mut self, other: DebugFlags)
The bitwise or (|
) of the bits in two flags values.
sourcepub fn remove(&mut self, other: DebugFlags)
pub fn remove(&mut self, other: DebugFlags)
The intersection of a source flags value with the complement of a target flags value (&!
).
This method is not equivalent to self & !other
when other
has unknown bits set.
remove
won’t truncate other
, but the !
operator will.
sourcepub fn toggle(&mut self, other: DebugFlags)
pub fn toggle(&mut self, other: DebugFlags)
The bitwise exclusive-or (^
) of the bits in two flags values.
sourcepub fn set(&mut self, other: DebugFlags, value: bool)
pub fn set(&mut self, other: DebugFlags, value: bool)
Call insert
when value
is true
or remove
when value
is false
.
sourcepub const fn intersection(self, other: DebugFlags) -> DebugFlags
pub const fn intersection(self, other: DebugFlags) -> DebugFlags
The bitwise and (&
) of the bits in two flags values.
sourcepub const fn union(self, other: DebugFlags) -> DebugFlags
pub const fn union(self, other: DebugFlags) -> DebugFlags
The bitwise or (|
) of the bits in two flags values.
sourcepub const fn difference(self, other: DebugFlags) -> DebugFlags
pub const fn difference(self, other: DebugFlags) -> DebugFlags
The intersection of a source flags value with the complement of a target flags value (&!
).
This method is not equivalent to self & !other
when other
has unknown bits set.
difference
won’t truncate other
, but the !
operator will.
sourcepub const fn symmetric_difference(self, other: DebugFlags) -> DebugFlags
pub const fn symmetric_difference(self, other: DebugFlags) -> DebugFlags
The bitwise exclusive-or (^
) of the bits in two flags values.
sourcepub const fn complement(self) -> DebugFlags
pub const fn complement(self) -> DebugFlags
The bitwise negation (!
) of the bits in a flags value, truncating the result.
source§impl DebugFlags
impl DebugFlags
sourcepub const fn iter(&self) -> Iter<DebugFlags>
pub const fn iter(&self) -> Iter<DebugFlags>
Yield a set of contained flags values.
Each yielded flags value will correspond to a defined named flag. Any unknown bits will be yielded together as a final flags value.
sourcepub const fn iter_names(&self) -> IterNames<DebugFlags>
pub const fn iter_names(&self) -> IterNames<DebugFlags>
Yield a set of contained named flags values.
This method is like iter
, except only yields bits in contained named flags.
Any unknown bits, or bits not corresponding to a contained flag will not be yielded.
Trait Implementations§
source§impl Binary for DebugFlags
impl Binary for DebugFlags
source§impl BitAnd for DebugFlags
impl BitAnd for DebugFlags
source§fn bitand(self, other: DebugFlags) -> DebugFlags
fn bitand(self, other: DebugFlags) -> DebugFlags
The bitwise and (&
) of the bits in two flags values.
§type Output = DebugFlags
type Output = DebugFlags
&
operator.source§impl BitAndAssign for DebugFlags
impl BitAndAssign for DebugFlags
source§fn bitand_assign(&mut self, other: DebugFlags)
fn bitand_assign(&mut self, other: DebugFlags)
The bitwise and (&
) of the bits in two flags values.
source§impl BitOr for DebugFlags
impl BitOr for DebugFlags
source§fn bitor(self, other: DebugFlags) -> DebugFlags
fn bitor(self, other: DebugFlags) -> DebugFlags
The bitwise or (|
) of the bits in two flags values.
§type Output = DebugFlags
type Output = DebugFlags
|
operator.source§impl BitOrAssign for DebugFlags
impl BitOrAssign for DebugFlags
source§fn bitor_assign(&mut self, other: DebugFlags)
fn bitor_assign(&mut self, other: DebugFlags)
The bitwise or (|
) of the bits in two flags values.
source§impl BitXor for DebugFlags
impl BitXor for DebugFlags
source§fn bitxor(self, other: DebugFlags) -> DebugFlags
fn bitxor(self, other: DebugFlags) -> DebugFlags
The bitwise exclusive-or (^
) of the bits in two flags values.
§type Output = DebugFlags
type Output = DebugFlags
^
operator.source§impl BitXorAssign for DebugFlags
impl BitXorAssign for DebugFlags
source§fn bitxor_assign(&mut self, other: DebugFlags)
fn bitxor_assign(&mut self, other: DebugFlags)
The bitwise exclusive-or (^
) of the bits in two flags values.
source§impl Clone for DebugFlags
impl Clone for DebugFlags
source§fn clone(&self) -> DebugFlags
fn clone(&self) -> DebugFlags
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for DebugFlags
impl Debug for DebugFlags
source§impl Default for DebugFlags
impl Default for DebugFlags
source§fn default() -> DebugFlags
fn default() -> DebugFlags
source§impl<'de> Deserialize<'de> for DebugFlags
impl<'de> Deserialize<'de> for DebugFlags
source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<DebugFlags, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<DebugFlags, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
source§impl Extend<DebugFlags> for DebugFlags
impl Extend<DebugFlags> for DebugFlags
source§fn extend<T>(&mut self, iterator: T)where
T: IntoIterator<Item = DebugFlags>,
fn extend<T>(&mut self, iterator: T)where
T: IntoIterator<Item = DebugFlags>,
The bitwise or (|
) of the bits in each flags value.
source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one
)source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one
)source§impl Flags for DebugFlags
impl Flags for DebugFlags
source§const FLAGS: &'static [Flag<DebugFlags>] = _
const FLAGS: &'static [Flag<DebugFlags>] = _
source§fn from_bits_retain(bits: u32) -> DebugFlags
fn from_bits_retain(bits: u32) -> DebugFlags
source§fn from_bits_truncate(bits: Self::Bits) -> Self
fn from_bits_truncate(bits: Self::Bits) -> Self
source§fn from_name(name: &str) -> Option<Self>
fn from_name(name: &str) -> Option<Self>
source§fn iter_names(&self) -> IterNames<Self>
fn iter_names(&self) -> IterNames<Self>
source§fn intersects(&self, other: Self) -> boolwhere
Self: Sized,
fn intersects(&self, other: Self) -> boolwhere
Self: Sized,
source§fn contains(&self, other: Self) -> boolwhere
Self: Sized,
fn contains(&self, other: Self) -> boolwhere
Self: Sized,
source§fn insert(&mut self, other: Self)where
Self: Sized,
fn insert(&mut self, other: Self)where
Self: Sized,
|
) of the bits in two flags values.source§fn remove(&mut self, other: Self)where
Self: Sized,
fn remove(&mut self, other: Self)where
Self: Sized,
&!
). Read moresource§fn toggle(&mut self, other: Self)where
Self: Sized,
fn toggle(&mut self, other: Self)where
Self: Sized,
^
) of the bits in two flags values.source§fn intersection(self, other: Self) -> Self
fn intersection(self, other: Self) -> Self
&
) of the bits in two flags values.source§fn difference(self, other: Self) -> Self
fn difference(self, other: Self) -> Self
&!
). Read moresource§fn symmetric_difference(self, other: Self) -> Self
fn symmetric_difference(self, other: Self) -> Self
^
) of the bits in two flags values.source§fn complement(self) -> Self
fn complement(self) -> Self
!
) of the bits in a flags value, truncating the result.source§impl FromIterator<DebugFlags> for DebugFlags
impl FromIterator<DebugFlags> for DebugFlags
source§fn from_iter<T>(iterator: T) -> DebugFlagswhere
T: IntoIterator<Item = DebugFlags>,
fn from_iter<T>(iterator: T) -> DebugFlagswhere
T: IntoIterator<Item = DebugFlags>,
The bitwise or (|
) of the bits in each flags value.
source§impl Hash for DebugFlags
impl Hash for DebugFlags
source§impl IntoIterator for DebugFlags
impl IntoIterator for DebugFlags
§type Item = DebugFlags
type Item = DebugFlags
§type IntoIter = Iter<DebugFlags>
type IntoIter = Iter<DebugFlags>
source§fn into_iter(self) -> <DebugFlags as IntoIterator>::IntoIter
fn into_iter(self) -> <DebugFlags as IntoIterator>::IntoIter
source§impl LowerHex for DebugFlags
impl LowerHex for DebugFlags
source§impl MallocSizeOf for DebugFlags
impl MallocSizeOf for DebugFlags
source§fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
source§impl Not for DebugFlags
impl Not for DebugFlags
source§fn not(self) -> DebugFlags
fn not(self) -> DebugFlags
The bitwise negation (!
) of the bits in a flags value, truncating the result.
§type Output = DebugFlags
type Output = DebugFlags
!
operator.source§impl Octal for DebugFlags
impl Octal for DebugFlags
source§impl Ord for DebugFlags
impl Ord for DebugFlags
source§fn cmp(&self, other: &DebugFlags) -> Ordering
fn cmp(&self, other: &DebugFlags) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
source§impl PartialEq for DebugFlags
impl PartialEq for DebugFlags
source§fn eq(&self, other: &DebugFlags) -> bool
fn eq(&self, other: &DebugFlags) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for DebugFlags
impl PartialOrd for DebugFlags
source§fn partial_cmp(&self, other: &DebugFlags) -> Option<Ordering>
fn partial_cmp(&self, other: &DebugFlags) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
self
and other
) and is used by the <=
operator. Read moresource§impl Serialize for DebugFlags
impl Serialize for DebugFlags
source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
source§impl Sub for DebugFlags
impl Sub for DebugFlags
source§fn sub(self, other: DebugFlags) -> DebugFlags
fn sub(self, other: DebugFlags) -> DebugFlags
The intersection of a source flags value with the complement of a target flags value (&!
).
This method is not equivalent to self & !other
when other
has unknown bits set.
difference
won’t truncate other
, but the !
operator will.
§type Output = DebugFlags
type Output = DebugFlags
-
operator.source§impl SubAssign for DebugFlags
impl SubAssign for DebugFlags
source§fn sub_assign(&mut self, other: DebugFlags)
fn sub_assign(&mut self, other: DebugFlags)
The intersection of a source flags value with the complement of a target flags value (&!
).
This method is not equivalent to self & !other
when other
has unknown bits set.
difference
won’t truncate other
, but the !
operator will.
source§impl UpperHex for DebugFlags
impl UpperHex for DebugFlags
impl Copy for DebugFlags
impl Eq for DebugFlags
impl StructuralPartialEq for DebugFlags
Auto Trait Implementations§
impl Freeze for DebugFlags
impl RefUnwindSafe for DebugFlags
impl Send for DebugFlags
impl Sync for DebugFlags
impl Unpin for DebugFlags
impl UnwindSafe for DebugFlags
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
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>
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>
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