Struct structural_shapes::CompositeShape [−][src]
pub struct CompositeShape {
pub shapes: Vec<(i8, StructuralShape)>,
}Expand description
A composite composed of multiple individual shapes
let x = CompositeShape::new()
.add(StructuralShape::Rod {
radius: length(2.0),
center_of_gravity: point(2.0, 0.0)
})
.add(StructuralShape::Rod {
radius: length(2.0),
center_of_gravity: point(-2.0, 0.0)
});Fields
shapes: Vec<(i8, StructuralShape)>Constituent shapes
Implementations
This function adds a new shape to the composite
This function subtracts a new shape to the composite
Calculate center of gravity and update COG of members
Shift structure to have cog at (0.0,0.0)
This function returns the moment of inertia of the composite shape around the x-axis
This function returns the moment of inertia of the composite shape around the y-axis
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for CompositeShape
impl Send for CompositeShape
impl Sync for CompositeShape
impl Unpin for CompositeShape
impl UnwindSafe for CompositeShape
Blanket Implementations
Mutably borrows from an owned value. Read more
