pub struct SoftBodyBuilder {Show 24 fields
pub positions: Vec<Vec2>,
pub masses: Vec<f32>,
pub particle_mass: f32,
pub pinned: Vec<u32>,
pub edges: Vec<[u32; 2]>,
pub bend_edges: Vec<[u32; 2]>,
pub tension_only_edges: Vec<u32>,
pub edge_softness: Vec<(u32, SpringCoefficients<f32>)>,
pub edge_tear_resistance: Vec<(u32, f32)>,
pub cells: Vec<[u32; 3]>,
pub surface: Vec<[u32; 2]>,
pub material: SoftBodyMaterial,
pub cell_model: SoftBodyCellModel,
pub volume_preservation: bool,
pub volume_factor: f32,
pub shape_matching: bool,
pub self_contacts: bool,
pub oriented: Option<bool>,
pub particle_radius: f32,
pub collider_template: Option<ColliderBuilder>,
pub skin: Option<(Vec<Vec2>, Vec<[u32; 2]>)>,
pub skin_collision: bool,
pub particle_settings: SoftBodyParticleSettings,
pub user_data: u128,
}Expand description
A builder for crate::dynamics::SoftBodys: particles are given in world space and elements
reference particles by index. The generators (Self::rope, plus cloth/cuboid/sphere
in 3D and polygon/disk/grid in 2D) make complete bodies; the setters build any body.
Fields§
§positions: Vec<Vec2>World-space particle positions.
masses: Vec<f32>Per-particle masses (empty = uniform particle_mass).
particle_mass: f32Uniform particle mass, used when masses is empty.
pinned: Vec<u32>Indices of the pinned particles.
edges: Vec<[u32; 2]>Structural edges (particle index pairs).
bend_edges: Vec<[u32; 2]>Bending edges (particle index pairs).
tension_only_edges: Vec<u32>Edges that only resist stretching, never compression (indices into the concatenation of
edges then bend_edges).
edge_softness: Vec<(u32, SpringCoefficients<f32>)>Per-edge softness overrides (indices into the concatenation of edges then
bend_edges); the material’s softness applies to the others.
edge_tear_resistance: Vec<(u32, f32)>Per-edge tear-threshold multipliers (indices into the concatenation of edges then
bend_edges, see crate::dynamics::SoftBodyEdge::tear_resistance); 1.0 for the others.
cells: Vec<[u32; 3]>Simplex cells (triangles in 2D, tetrahedra in 3D).
surface: Vec<[u32; 2]>Boundary elements (segments in 2D, triangles in 3D), oriented outward. Derived from the cells when empty.
material: SoftBodyMaterialThe material.
cell_model: SoftBodyCellModelThe constitutive model of the cells.
volume_preservation: boolWhether area/volume preservation is enabled (one constraint per piece of material enclosed by a closed surface).
volume_factor: f32Target volume multiplier (> 1 inflates the body).
shape_matching: boolWhether shape matching is enabled.
self_contacts: boolWhether the body’s surface collides with itself.
oriented: Option<bool>Whether the default collision surface’s shape is built with parry’s ORIENTED flag
(see Self::oriented); None: when the surface is closed.
particle_radius: f32Thickness of the particles: the contact skin of the body’s surface collider.
collider_template: Option<ColliderBuilder>Template of the colliders of the body’s collision meshes (their shape is the mesh’s own);
None disables collisions.
skin: Option<(Vec<Vec2>, Vec<[u32; 2]>)>Mesh held by the cells, if any: (vertices, elements) in world space, bound to the
cells at build time.
skin_collision: boolWhether the body meets the world through its skin rather than through its cells’ boundary (off by default, and no effect without a skin).
particle_settings: SoftBodyParticleSettingsDynamics settings of the particles.
user_data: u128User data of the soft body.
Implementations§
Source§impl SoftBodyBuilder
impl SoftBodyBuilder
Sourcepub fn particle_positions(&self) -> &[Vec2]
pub fn particle_positions(&self) -> &[Vec2]
The particle positions set so far.
Sourcepub fn positions(self, positions: Vec<Vec2>) -> SoftBodyBuilder
pub fn positions(self, positions: Vec<Vec2>) -> SoftBodyBuilder
Sets the world-space positions of the particles.
Sourcepub fn particle_mass(self, mass: f32) -> SoftBodyBuilder
pub fn particle_mass(self, mass: f32) -> SoftBodyBuilder
Sets the mass of every particle.
Sourcepub fn mass(self, mass: f32) -> SoftBodyBuilder
pub fn mass(self, mass: f32) -> SoftBodyBuilder
Sets the total mass of the soft body (split uniformly across the particles).
Sourcepub fn masses(self, masses: Vec<f32>) -> SoftBodyBuilder
pub fn masses(self, masses: Vec<f32>) -> SoftBodyBuilder
Sets per-particle masses.
Sourcepub fn pinned_particles(
self,
pinned: impl IntoIterator<Item = u32>,
) -> SoftBodyBuilder
pub fn pinned_particles( self, pinned: impl IntoIterator<Item = u32>, ) -> SoftBodyBuilder
Pins the given particles (infinite mass, moved kinematically: see
crate::dynamics::SoftBody::set_particle_kinematic_target).
Sourcepub fn add_edges(
self,
edges: impl IntoIterator<Item = [u32; 2]>,
) -> SoftBodyBuilder
pub fn add_edges( self, edges: impl IntoIterator<Item = [u32; 2]>, ) -> SoftBodyBuilder
Adds structural edges (seams between two appended pieces, extra springs…); their rest length is the current distance of their particles.
Sourcepub fn append(self, other: SoftBodyBuilder) -> SoftBodyBuilder
pub fn append(self, other: SoftBodyBuilder) -> SoftBodyBuilder
Appends the particles and elements of other (its indices shifted past this builder’s
particles): the two pieces become one soft body, to be sewn together with
Self::add_edges. This builder’s material, model and settings are kept.
Sourcepub fn bend_edges(self, edges: Vec<[u32; 2]>) -> SoftBodyBuilder
pub fn bend_edges(self, edges: Vec<[u32; 2]>) -> SoftBodyBuilder
Sets the bending edges.
Sourcepub fn tension_only(self) -> SoftBodyBuilder
pub fn tension_only(self) -> SoftBodyBuilder
Makes every edge (structural and bending) only resist stretching, never compression.
Sourcepub fn cells(self, cells: Vec<[u32; 3]>) -> SoftBodyBuilder
pub fn cells(self, cells: Vec<[u32; 3]>) -> SoftBodyBuilder
Sets the simplex cells (triangles in 2D, tetrahedra in 3D). Structural edges along the cell edges are added at build time if none were given.
Sourcepub fn translated(self, translation: Vec2) -> SoftBodyBuilder
pub fn translated(self, translation: Vec2) -> SoftBodyBuilder
Moves everything the builder holds in world space: the particles and the skin.
Useful to drop copies of a meshed body at several places without meshing it again; moving the particles alone would leave the skin behind.
Sourcepub fn skin(
self,
vertices: Vec<Vec2>,
indices: Vec<[u32; 2]>,
) -> SoftBodyBuilder
pub fn skin( self, vertices: Vec<Vec2>, indices: Vec<[u32; 2]>, ) -> SoftBodyBuilder
Sets the mesh the cells hold: the body’s default collision mesh is then that mesh, bound to
the cells (crate::dynamics::SoftMeshMapping::Skinned) instead of the cells’ boundary.
The vertices are in world space in the cells’ build pose, each bound to the closest cell.
Sourcepub fn skin_collision(self, enabled: bool) -> SoftBodyBuilder
pub fn skin_collision(self, enabled: bool) -> SoftBodyBuilder
Whether the body’s skin is its collision mesh rather than its cells’ boundary (off by default, and no effect without a skin); on, a contact is resolved through the particles of the cell holding the touched part of the skin, which must be at least as fine as the cells.
Sourcepub fn surface(self, surface: Vec<[u32; 2]>) -> SoftBodyBuilder
pub fn surface(self, surface: Vec<[u32; 2]>) -> SoftBodyBuilder
Sets the computational mesh’s boundary elements (segments in 2D, triangles in 3D), oriented outward: what the volume constraint integrates over, and the geometry of the default collision mesh.
Sourcepub fn material(self, material: SoftBodyMaterial) -> SoftBodyBuilder
pub fn material(self, material: SoftBodyMaterial) -> SoftBodyBuilder
Sets the material.
Sourcepub fn softness(self, softness: SpringCoefficients<f32>) -> SoftBodyBuilder
pub fn softness(self, softness: SpringCoefficients<f32>) -> SoftBodyBuilder
Sets the same softness for every constraint family.
Sourcepub fn tear_strain(self, strain: f32) -> SoftBodyBuilder
pub fn tear_strain(self, strain: f32) -> SoftBodyBuilder
Sets the material’s tear strain (see SoftBodyMaterial::tear_strain).
Sourcepub fn tear_force(self, force: f32) -> SoftBodyBuilder
pub fn tear_force(self, force: f32) -> SoftBodyBuilder
Sets the material’s tear force (see SoftBodyMaterial::tear_force).
Sourcepub fn min_piece(self, elements: u32) -> SoftBodyBuilder
pub fn min_piece(self, elements: u32) -> SoftBodyBuilder
Sets the smallest piece, in measure elements, a tear may split off (see
SoftBodyMaterial::min_piece).
Sourcepub fn tear_smoothing(self, seconds: f32) -> SoftBodyBuilder
pub fn tear_smoothing(self, seconds: f32) -> SoftBodyBuilder
Sets the material’s tear smoothing time constant (see
SoftBodyMaterial::tear_smoothing).
Sourcepub fn interior_strength(self, strength: f32) -> SoftBodyBuilder
pub fn interior_strength(self, strength: f32) -> SoftBodyBuilder
Sets the material’s interior strength (see SoftBodyMaterial::interior_strength).
Sourcepub fn edge_tear_resistance(
self,
edges: impl IntoIterator<Item = (u32, f32)>,
) -> SoftBodyBuilder
pub fn edge_tear_resistance( self, edges: impl IntoIterator<Item = (u32, f32)>, ) -> SoftBodyBuilder
Sets the tear-threshold multiplier of some edges, as (edge index, resistance) pairs
indexing the concatenation of the structural then the bending edges (see
crate::dynamics::SoftBodyEdge::tear_resistance).
Sourcepub fn cell_model(self, model: SoftBodyCellModel) -> SoftBodyBuilder
pub fn cell_model(self, model: SoftBodyCellModel) -> SoftBodyBuilder
Sets the constitutive model of the cells.
Sourcepub fn volume_preservation(self, enabled: bool) -> SoftBodyBuilder
pub fn volume_preservation(self, enabled: bool) -> SoftBodyBuilder
Enables area/volume preservation: one constraint per piece of material enclosed by a
closed surface (see crate::dynamics::SoftBody::volume_pieces).
Sourcepub fn volume_factor(self, factor: f32) -> SoftBodyBuilder
pub fn volume_factor(self, factor: f32) -> SoftBodyBuilder
Sets the target volume multiplier (> 1 inflates the body).
Sourcepub fn shape_matching(self, enabled: bool) -> SoftBodyBuilder
pub fn shape_matching(self, enabled: bool) -> SoftBodyBuilder
Enables shape matching.
Sourcepub fn self_contacts(self, enabled: bool) -> SoftBodyBuilder
pub fn self_contacts(self, enabled: bool) -> SoftBodyBuilder
Enables self contacts between the body’s surface vertices/edges and its own surface.
Sourcepub fn oriented(self, oriented: bool) -> SoftBodyBuilder
pub fn oriented(self, oriented: bool) -> SoftBodyBuilder
Whether the shape of the body’s default collision surface is built with parry’s
ORIENTED flag, like a rigid polyline or mesh. Left unset, it is whenever the surface is
closed, which is what a solid body wants: an oriented closed surface encloses matter, so
nothing is held inside it. Set it to false for a shell, whose inner side holds the bodies
inside it. After insertion the collider’s shape is the authority: change its flags there,
like for any collider. Independent of the material inside (cells, pressure).
Sourcepub fn particle_radius(self, radius: f32) -> SoftBodyBuilder
pub fn particle_radius(self, radius: f32) -> SoftBodyBuilder
Sets the thickness of the particles (the contact skin of the body’s surface collider).
Sourcepub fn surface_collider(self, collider: ColliderBuilder) -> SoftBodyBuilder
pub fn surface_collider(self, collider: ColliderBuilder) -> SoftBodyBuilder
Configures the collider of the body’s default collision mesh (its cells’ boundary, or its
skin under Self::skin_collision): friction, restitution, groups, events. The shape is
the mesh’s own; the density is ignored (mass from Self::mass or Self::masses).
Sourcepub fn no_surface_collider(self) -> SoftBodyBuilder
pub fn no_surface_collider(self) -> SoftBodyBuilder
Gives the body no default collision mesh collider: it collides through the meshes added after insertion, if any.
Sourcepub fn particle_settings(
self,
settings: SoftBodyParticleSettings,
) -> SoftBodyBuilder
pub fn particle_settings( self, settings: SoftBodyParticleSettings, ) -> SoftBodyBuilder
Sets the dynamics settings of the particles (damping, gravity scale, sleeping…).
Sourcepub fn linear_damping(self, damping: f32) -> SoftBodyBuilder
pub fn linear_damping(self, damping: f32) -> SoftBodyBuilder
Sets the linear damping of the particles.
Sourcepub fn gravity_scale(self, scale: f32) -> SoftBodyBuilder
pub fn gravity_scale(self, scale: f32) -> SoftBodyBuilder
Sets the gravity scale of the particles.
Sourcepub fn additional_solver_iterations(self, iterations: usize) -> SoftBodyBuilder
pub fn additional_solver_iterations(self, iterations: usize) -> SoftBodyBuilder
Requests extra solver substeps for the particles (and everything they touch).
Sourcepub fn additional_pgs_iterations(self, iterations: usize) -> SoftBodyBuilder
pub fn additional_pgs_iterations(self, iterations: usize) -> SoftBodyBuilder
Requests extra internal PGS iterations per substep for the particles (and everything
they touch); see SoftBodyParticleSettings::additional_pgs_iterations.
Sourcepub fn can_sleep(self, can_sleep: bool) -> SoftBodyBuilder
pub fn can_sleep(self, can_sleep: bool) -> SoftBodyBuilder
Whether the particles may fall asleep.
Sourcepub fn user_data(self, data: u128) -> SoftBodyBuilder
pub fn user_data(self, data: u128) -> SoftBodyBuilder
Sets the user data of the soft body.
Sourcepub fn surface_edges(&self) -> Vec<[u32; 2]>
pub fn surface_edges(&self) -> Vec<[u32; 2]>
The unique edges of the surface elements.
Sourcepub fn cell_edges(&self) -> Vec<[u32; 2]>
pub fn cell_edges(&self) -> Vec<[u32; 2]>
The unique edges of the cells.
Source§impl SoftBodyBuilder
impl SoftBodyBuilder
Sourcepub fn new(positions: Vec<Vec2>) -> SoftBodyBuilder
pub fn new(positions: Vec<Vec2>) -> SoftBodyBuilder
A builder over the given world-space particle positions, with no element.
Sourcepub fn trimesh(
vertices: Vec<Vec2>,
indices: Vec<[u32; 3]>,
) -> Option<SoftBodyBuilder>
pub fn trimesh( vertices: Vec<Vec2>, indices: Vec<[u32; 3]>, ) -> Option<SoftBodyBuilder>
A triangle-mesh soft body without volumetric cells (None if empty): vertices are
particles, edges are structural and shape matching holds the shape. 3D: the triangles are
the surface (dihedral bending across interior edges); 2D: the boundary is the surface.
Sourcepub fn polyline(
vertices: Vec<Vec2>,
indices: Option<Vec<[u32; 2]>>,
) -> Option<SoftBodyBuilder>
pub fn polyline( vertices: Vec<Vec2>, indices: Option<Vec<[u32; 2]>>, ) -> Option<SoftBodyBuilder>
A soft body from a polyline (2D only): particles at the vertices, structural edges and the
surface on the segments, bending edges at two-segment vertices, shape matching, an inside
(Self::volume_preservation) if closed counter-clockwise; None for an empty polyline.
Sourcepub fn rope(start: Vec2, end: Vec2, num_particles: usize) -> SoftBodyBuilder
pub fn rope(start: Vec2, end: Vec2, num_particles: usize) -> SoftBodyBuilder
A rope of num_particles particles from start to end: structural edges between
neighbors, bending edges between second neighbors; in 2D the segments are also the surface.
The particle radius (the rope’s thickness) defaults to half the segment length.
Sourcepub fn volumetric(
vertices: &[Vec2],
indices: &[[u32; 2]],
cell_size: f32,
) -> Option<SoftBodyBuilder>
pub fn volumetric( vertices: &[Vec2], indices: &[[u32; 2]], cell_size: f32, ) -> Option<SoftBodyBuilder>
A volumetric body filling a closed, outward-oriented mesh (triangles in 3D, segments in 2D)
with cells of size cell_size; the surface is their boundary. Particle radius defaults to
half the mean cell edge; None if the mesh is empty, open or encloses nothing at that size.
Sourcepub fn volumetric_with(
vertices: &[Vec2],
indices: &[[u32; 2]],
params: &VolumeMeshParameters,
) -> Option<SoftBodyBuilder>
pub fn volumetric_with( vertices: &[Vec2], indices: &[[u32; 2]], params: &VolumeMeshParameters, ) -> Option<SoftBodyBuilder>
The same as Self::volumetric, with the meshing parameters spelled out: element size,
the cover’s smoothing, guard and subdivision, and whether the surface alone is covered
(the crust).
Sourcepub fn volumetric_skinned(
vertices: &[Vec2],
indices: &[[u32; 2]],
cell_size: f32,
) -> Option<SoftBodyBuilder>
pub fn volumetric_skinned( vertices: &[Vec2], indices: &[[u32; 2]], cell_size: f32, ) -> Option<SoftBodyBuilder>
The same as Self::volumetric, keeping the boundary mesh as the body’s skin: the cells
hold it and the body is drawn as it, so thin features survive a cell size that cannot
resolve them; it still collides through its cells, so contacts are as coarse as they are.
Sourcepub fn polygon(points: Vec<Vec2>) -> SoftBodyBuilder
pub fn polygon(points: Vec<Vec2>) -> SoftBodyBuilder
A closed polygon (counter-clockwise points): structural edges along the boundary,
bending edges between second neighbors, and area preservation (2D only).
The particle radius defaults to half the mean edge length.
Sourcepub fn disk(center: Vec2, radius: f32, num_particles: usize) -> SoftBodyBuilder
pub fn disk(center: Vec2, radius: f32, num_particles: usize) -> SoftBodyBuilder
A regular polygon with num_particles boundary particles (see Self::polygon, 2D only).
Sourcepub fn grid(
center: Vec2,
half_extents: Vec2,
nx: usize,
ny: usize,
) -> SoftBodyBuilder
pub fn grid( center: Vec2, half_extents: Vec2, nx: usize, ny: usize, ) -> SoftBodyBuilder
A solid rectangle triangulated on a nx × ny particle grid (2D only), with structural
edges along the triangle edges and the boundary segments as surface.
The particle radius defaults to half the smallest cell size.
Trait Implementations§
Source§impl Clone for SoftBodyBuilder
impl Clone for SoftBodyBuilder
Source§fn clone(&self) -> SoftBodyBuilder
fn clone(&self) -> SoftBodyBuilder
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 SoftBodyBuilder
impl Debug for SoftBodyBuilder
Source§impl Default for SoftBodyBuilder
impl Default for SoftBodyBuilder
Source§fn default() -> SoftBodyBuilder
fn default() -> SoftBodyBuilder
Source§impl From<SoftBodyBuilder> for SoftBody
impl From<SoftBodyBuilder> for SoftBody
Source§fn from(builder: SoftBodyBuilder) -> SoftBody
fn from(builder: SoftBodyBuilder) -> SoftBody
Source§impl From<SoftBodyBuilder> for SoftBody
impl From<SoftBodyBuilder> for SoftBody
Source§fn from(builder: SoftBodyBuilder) -> Self
fn from(builder: SoftBodyBuilder) -> Self
Auto Trait Implementations§
impl !RefUnwindSafe for SoftBodyBuilder
impl !UnwindSafe for SoftBodyBuilder
impl Freeze for SoftBodyBuilder
impl Send for SoftBodyBuilder
impl Sync for SoftBodyBuilder
impl Unpin for SoftBodyBuilder
impl UnsafeUnpin for SoftBodyBuilder
Blanket Implementations§
Source§impl<T, U> AsBindGroupShaderType<U> for T
impl<T, U> AsBindGroupShaderType<U> for T
Source§fn as_bind_group_shader_type(&self, _images: &RenderAssets<GpuImage>) -> U
fn as_bind_group_shader_type(&self, _images: &RenderAssets<GpuImage>) -> U
T ShaderType for self. When used in AsBindGroup
derives, it is safe to assume that all images in self exist.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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> ConditionalSend for Twhere
T: Send,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be
downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further
downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSend for T
impl<T> DowncastSend for T
Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
Source§impl<T> FromTemplate for T
impl<T> FromTemplate for T
Source§impl<T> FromWorld for Twhere
T: Default,
impl<T> FromWorld for Twhere
T: Default,
Source§fn from_world(_world: &mut World) -> T
fn from_world(_world: &mut World) -> T
Creates Self using default().
Source§impl<T, W> HasTypeWitness<W> for Twhere
W: MakeTypeWitness<Arg = T>,
T: ?Sized,
impl<T, W> HasTypeWitness<W> for Twhere
W: MakeTypeWitness<Arg = T>,
T: ?Sized,
Source§impl<T> Identity for Twhere
T: ?Sized,
impl<T> Identity for Twhere
T: ?Sized,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
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 moreSource§impl<T> IntoResult<T> for T
impl<T> IntoResult<T> for T
Source§fn into_result(self) -> Result<T, RunSystemError>
fn into_result(self) -> Result<T, RunSystemError>
impl<T> MaybeSync for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
impl<T> Settings for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.Source§impl<T> Template for T
impl<T> Template for T
Source§fn build_template(
&self,
_context: &mut TemplateContext<'_, '_>,
) -> Result<<T as Template>::Output, BevyError>
fn build_template( &self, _context: &mut TemplateContext<'_, '_>, ) -> Result<<T as Template>::Output, BevyError>
entity context to produce a Template::Output.Source§fn clone_template(&self) -> T
fn clone_template(&self) -> T
Clone.Source§impl<T> TypeData for T
impl<T> TypeData for T
Source§fn clone_type_data(&self) -> Box<dyn TypeData>
fn clone_type_data(&self) -> Box<dyn TypeData>
self.