pub struct AdvancedSculpt;Implementations§
Source§impl AdvancedSculpt
impl AdvancedSculpt
Sourcepub fn global_relax(
model: &mut ParticleModel,
iterations: usize,
strength: f32,
neighbor_radius: f32,
)
pub fn global_relax( model: &mut ParticleModel, iterations: usize, strength: f32, neighbor_radius: f32, )
Relax particles: iterative Laplacian smoothing over the whole model.
Sourcepub fn jitter(
model: &mut ParticleModel,
indices: &HashSet<usize>,
amplitude: f32,
seed: u32,
)
pub fn jitter( model: &mut ParticleModel, indices: &HashSet<usize>, amplitude: f32, seed: u32, )
Jitter: add random noise to particle positions.
Sourcepub fn shrink_wrap_sphere(
model: &mut ParticleModel,
indices: &HashSet<usize>,
center: Vec3,
radius: f32,
blend: f32,
)
pub fn shrink_wrap_sphere( model: &mut ParticleModel, indices: &HashSet<usize>, center: Vec3, radius: f32, blend: f32, )
Shrink-wrap: project each particle onto the surface of a target sphere.
Sourcepub fn push_to_aabb_surface(
model: &mut ParticleModel,
indices: &HashSet<usize>,
aabb: &Aabb3,
blend: f32,
)
pub fn push_to_aabb_surface( model: &mut ParticleModel, indices: &HashSet<usize>, aabb: &Aabb3, blend: f32, )
Push particles inside AABB to the surface.
Sourcepub fn array_duplicate(
model: &mut ParticleModel,
indices: &HashSet<usize>,
count: usize,
step: Vec3,
)
pub fn array_duplicate( model: &mut ParticleModel, indices: &HashSet<usize>, count: usize, step: Vec3, )
Array duplicate: create N copies of the selection along an axis.
Sourcepub fn radial_array(
model: &mut ParticleModel,
indices: &HashSet<usize>,
center: Vec3,
axis: Vec3,
count: usize,
)
pub fn radial_array( model: &mut ParticleModel, indices: &HashSet<usize>, center: Vec3, axis: Vec3, count: usize, )
Radial array: place copies at evenly spaced angles around an axis.
Sourcepub fn merge_by_distance(model: &mut ParticleModel, threshold: f32)
pub fn merge_by_distance(model: &mut ParticleModel, threshold: f32)
Merge nearby particles within a threshold distance.
Sourcepub fn find_connected_components(
model: &ParticleModel,
max_edge_len: f32,
) -> Vec<Vec<usize>>
pub fn find_connected_components( model: &ParticleModel, max_edge_len: f32, ) -> Vec<Vec<usize>>
Separate disconnected components into individual models.
Sourcepub fn convex_hull_center(model: &ParticleModel) -> Vec3
pub fn convex_hull_center(model: &ParticleModel) -> Vec3
Compute the convex hull center (centroid of bounding box corners).
Sourcepub fn normalize_scale(model: &mut ParticleModel)
pub fn normalize_scale(model: &mut ParticleModel)
Scale model to fit in a unit cube.
Auto Trait Implementations§
impl Freeze for AdvancedSculpt
impl RefUnwindSafe for AdvancedSculpt
impl Send for AdvancedSculpt
impl Sync for AdvancedSculpt
impl Unpin for AdvancedSculpt
impl UnsafeUnpin for AdvancedSculpt
impl UnwindSafe for AdvancedSculpt
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
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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>
Convert
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<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>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> 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)
Convert
&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)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.