#[repr(i32)]
pub enum PxVisualizationParameter {
Show 27 variants Scale, WorldAxes, BodyAxes, BodyMassAxes, BodyLinVelocity, BodyAngVelocity, ContactPoint, ContactNormal, ContactError, ContactForce, ActorAxes, CollisionAabbs, CollisionShapes, CollisionAxes, CollisionCompounds, CollisionFnormals, CollisionEdges, CollisionStatic, CollisionDynamic, JointLocalFrames, JointLimits, CullBox, MbpRegions, SimulationMesh, Sdf, NumValues, ForceDword,
}
Expand description

Debug visualization parameters.

[PxVisualizationParameter::eSCALE] is the master switch for enabling visualization, please read the corresponding documentation for further details.

Variants§

§

Scale

This overall visualization scale gets multiplied with the individual scales. Setting to zero ignores all visualizations. Default is 0.

The below settings permit the debug visualization of various simulation properties. The setting is either zero, in which case the property is not drawn. Otherwise it is a scaling factor that determines the size of the visualization widgets.

Only objects for which visualization is turned on using setFlag(eVISUALIZATION) are visualized (see [PxActorFlag::eVISUALIZATION], #PxShapeFlag::eVISUALIZATION, …). Contacts are visualized if they involve a body which is being visualized. Default is 0.

Notes:

  • to see any visualization, you have to set PxVisualizationParameter::eSCALE to nonzero first.
  • the scale factor has been introduced because it’s difficult (if not impossible) to come up with a good scale for 3D vectors. Normals are normalized and their length is always 1. But it doesn’t mean we should render a line of length 1. Depending on your objects/scene, this might be completely invisible or extremely huge. That’s why the scale factor is here, to let you tune the length until it’s ok in your scene.
  • however, things like collision shapes aren’t ambiguous. They are clearly defined for example by the triangles & polygons themselves, and there’s no point in scaling that. So the visualization widgets are only scaled when it makes sense.

Range: [0, PX_MAX_F32) Default: 0

§

WorldAxes

Visualize the world axes.

§

BodyAxes

Visualize a bodies axes.

§

BodyMassAxes

Visualize a body’s mass axes.

This visualization is also useful for visualizing the sleep state of bodies. Sleeping bodies are drawn in black, while awake bodies are drawn in white. If the body is sleeping and part of a sleeping group, it is drawn in red.

§

BodyLinVelocity

Visualize the bodies linear velocity.

§

BodyAngVelocity

Visualize the bodies angular velocity.

§

ContactPoint

Visualize contact points. Will enable contact information.

§

ContactNormal

Visualize contact normals. Will enable contact information.

§

ContactError

Visualize contact errors. Will enable contact information.

§

ContactForce

Visualize Contact forces. Will enable contact information.

§

ActorAxes

Visualize actor axes.

§

CollisionAabbs

Visualize bounds (AABBs in world space)

§

CollisionShapes

Shape visualization

§

CollisionAxes

Shape axis visualization

§

CollisionCompounds

Compound visualization (compound AABBs in world space)

§

CollisionFnormals

Mesh & convex face normals

§

CollisionEdges

Active edges for meshes

§

CollisionStatic

Static pruning structures

§

CollisionDynamic

Dynamic pruning structures

§

JointLocalFrames

Joint local axes

§

JointLimits

Joint limits

§

CullBox

Visualize culling box

§

MbpRegions

MBP regions

§

SimulationMesh

Renders the simulation mesh instead of the collision mesh (only available for tetmeshes)

§

Sdf

Renders the SDF of a mesh instead of the collision mesh (only available for triangle meshes with SDFs)

§

NumValues

This is not a parameter, it just records the current number of parameters (as maximum(PxVisualizationParameter)+1) for use in loops.

§

ForceDword

This is not a parameter, it just records the current number of parameters (as maximum(PxVisualizationParameter)+1) for use in loops.

Trait Implementations§

source§

impl Clone for PxVisualizationParameter

source§

fn clone(&self) -> PxVisualizationParameter

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for PxVisualizationParameter

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl PartialEq<PxVisualizationParameter> for PxVisualizationParameter

source§

fn eq(&self, other: &PxVisualizationParameter) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Copy for PxVisualizationParameter

source§

impl Eq for PxVisualizationParameter

source§

impl StructuralEq for PxVisualizationParameter

source§

impl StructuralPartialEq for PxVisualizationParameter

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

const: unstable · source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

const: unstable · source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

const: unstable · source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere U: From<T>,

const: unstable · source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for Twhere T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
const: unstable · source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
const: unstable · source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.