Skip to main content

StaticMeshBakeError

Enum StaticMeshBakeError 

Source
#[non_exhaustive]
pub enum StaticMeshBakeError {
Show 18 variants NoInstances, MeshInstanceCount { mesh: usize, source_mesh_index: usize, instances: usize, }, MissingMesh { source_node_index: usize, mesh: usize, }, MissingNode { source_node_index: usize, node: usize, }, DuplicateNodeAttachment { source_node_index: usize, }, DuplicateSkeletonNodeAttachment { node: usize, }, AnimationTrack { clip: String, node: usize, property: &'static str, }, SkeletonSkin { node: usize, }, SkinnedInstance { source_node_index: usize, }, SkinnedPrimitive { mesh: usize, primitive: usize, }, InvalidParent { node: usize, parent: usize, }, NonFiniteTransform { node: usize, }, InvalidPrimitive { mesh: usize, primitive: usize, reason: &'static str, }, NonFiniteMaterial { material: usize, factor: &'static str, }, NonFiniteAttribute { mesh: usize, primitive: usize, attribute: &'static str, vertex: usize, }, ZeroNormal { mesh: usize, primitive: usize, vertex: usize, }, SingularTransform { source_node_index: usize, determinant: f32, }, ReflectionTransform { source_node_index: usize, determinant: f32, },
}
Expand description

Rejection reason returned by bake_static_mesh_transforms.

Variants (Non-exhaustive)§

This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
§

NoInstances

The input carries no mesh-node attachments to bake.

§

MeshInstanceCount

An input mesh definition is not attached to exactly one mesh node.

Fields

§mesh: usize

Ordinal in SceneAssets::meshes.

§source_mesh_index: usize

Source mesh identity.

§instances: usize

Number of input instances that reference the definition.

§

MissingMesh

A mesh instance references a mesh definition that does not exist.

Fields

§source_node_index: usize

Source node identity from the instance.

§mesh: usize

Missing mesh ordinal.

§

MissingNode

A mesh instance references a skeleton node that does not exist.

Fields

§source_node_index: usize

Source node identity from the instance.

§node: usize

Missing skeleton node ordinal.

§

DuplicateNodeAttachment

More than one model instance claims one source mesh node.

Fields

§source_node_index: usize

Source node identity claimed more than once.

§

DuplicateSkeletonNodeAttachment

More than one model instance attaches a mesh to one internal skeleton node.

Fields

§node: usize

Internal skeleton node claimed more than once.

§

AnimationTrack

The input contains animation data, which a static-only bake cannot retain.

Fields

§clip: String

Clip name.

§node: usize

Target skeleton node.

§property: &'static str

Animated property name.

§

SkeletonSkin

A skeleton carries inverse-bind data, indicating a skin domain.

Fields

§node: usize

Skeleton node carrying inverse-bind data.

§

SkinnedInstance

A mesh instance carries skin joints or inverse bind matrices.

Fields

§source_node_index: usize

Source node identity from the instance.

§

SkinnedPrimitive

A primitive carries skin vertex attributes.

Fields

§mesh: usize

Input mesh ordinal.

§primitive: usize

Primitive ordinal within the mesh.

§

InvalidParent

A skeleton parent is absent or is not earlier than its child.

Fields

§node: usize

Skeleton node ordinal.

§parent: usize

Invalid parent ordinal.

§

NonFiniteTransform

A local or accumulated matrix has a non-finite component.

Fields

§node: usize

Skeleton node ordinal.

§

InvalidPrimitive

A mesh primitive has malformed attributes, indices, or material data.

Fields

§mesh: usize

Input mesh ordinal.

§primitive: usize

Primitive ordinal within the mesh.

§reason: &'static str

Stable machine-readable reason.

§

NonFiniteMaterial

A material factor contains a non-finite value.

Fields

§material: usize

Material ordinal.

§factor: &'static str

Material factor name.

§

NonFiniteAttribute

A position, normal, or UV contains a non-finite component.

Fields

§mesh: usize

Input mesh ordinal.

§primitive: usize

Primitive ordinal within the mesh.

§attribute: &'static str

Attribute name.

§vertex: usize

Vertex ordinal.

§

ZeroNormal

A normal cannot be normalized after applying the normal matrix.

Fields

§mesh: usize

Input mesh ordinal.

§primitive: usize

Primitive ordinal within the mesh.

§vertex: usize

Vertex ordinal.

§

SingularTransform

A linear transform is singular or too close to singular for a stable inverse transpose.

Fields

§source_node_index: usize

Source node identity from the instance.

§determinant: f32

Linear determinant.

§

ReflectionTransform

A linear transform reverses winding, which would require changing preserved indices.

Fields

§source_node_index: usize

Source node identity from the instance.

§determinant: f32

Linear determinant.

Trait Implementations§

Source§

impl Debug for StaticMeshBakeError

Source§

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

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

impl Display for StaticMeshBakeError

Source§

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

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

impl Error for StaticMeshBakeError

1.30.0 · Source§

fn source(&self) -> Option<&(dyn Error + 'static)>

Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§

fn description(&self) -> &str

👎Deprecated since 1.42.0:

use the Display impl or to_string()

1.0.0 · Source§

fn cause(&self) -> Option<&dyn Error>

👎Deprecated since 1.33.0:

replaced by Error::source, which can support downcasting

Source§

fn provide<'a>(&'a self, request: &mut Request<'a>)

🔬This is a nightly-only experimental API. (error_generic_member_access)
Provides type-based access to context intended for error reports. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

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

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

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

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

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

Source§

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

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

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

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> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

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

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

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

Performs the conversion.
Source§

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

Source§

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

The type returned in the event of a conversion error.
Source§

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

Performs the conversion.