pub struct RevolutionSurface { /* private fields */ }Expand description
A curve revolved about an axis.
u is the angle of revolution; v is the generating curve’s own parameter.
Implementations§
Source§impl RevolutionSurface
impl RevolutionSurface
Sourcepub fn new(curve: Curve, axis: Axis, angle: f64) -> OgeomResult<Self>
pub fn new(curve: Curve, axis: Axis, angle: f64) -> OgeomResult<Self>
Revolve curve about axis through angle radians.
§Errors
OgeomError::Construction if the angle
is not finite and positive, or exceeds a full turn.
Sourcepub fn over(curve: Curve, axis: Axis, range: (f64, f64)) -> OgeomResult<Self>
pub fn over(curve: Curve, axis: Axis, range: (f64, f64)) -> OgeomResult<Self>
Revolve curve about axis over the angles range, which may
start anywhere: the point at angle u is the curve turned by u, as
for RevolutionSurface::new, so a wider range sweeps the same
surface further either way, its parameters kept.
§Errors
OgeomError::Construction if the range
is not finite, empty, or spans more than a full turn.
Trait Implementations§
Source§impl Clone for RevolutionSurface
impl Clone for RevolutionSurface
Source§impl Debug for RevolutionSurface
impl Debug for RevolutionSurface
Source§impl From<RevolutionSurface> for SurfaceGeometry
impl From<RevolutionSurface> for SurfaceGeometry
Source§fn from(s: RevolutionSurface) -> Self
fn from(s: RevolutionSurface) -> Self
Converts to this type from the input type.
Source§impl PartialEq for RevolutionSurface
impl PartialEq for RevolutionSurface
impl StructuralPartialEq for RevolutionSurface
Source§impl Surface for RevolutionSurface
impl Surface for RevolutionSurface
Source§fn point_at(&self, u: f64, v: f64, tol: Tolerances) -> OgeomResult<Point>
fn point_at(&self, u: f64, v: f64, tol: Tolerances) -> OgeomResult<Point>
The point at
(u, v). Read moreSource§fn d1_at(
&self,
u: f64,
v: f64,
tol: Tolerances,
) -> OgeomResult<(Vector, Vector)>
fn d1_at( &self, u: f64, v: f64, tol: Tolerances, ) -> OgeomResult<(Vector, Vector)>
The two first derivatives at
(u, v). Read moreSource§fn d2_at(
&self,
u: f64,
v: f64,
tol: Tolerances,
) -> OgeomResult<(Vector, Vector, Vector)>
fn d2_at( &self, u: f64, v: f64, tol: Tolerances, ) -> OgeomResult<(Vector, Vector, Vector)>
Source§fn kind(&self) -> SurfaceKind
fn kind(&self) -> SurfaceKind
What kind of surface this is.
Source§fn continuity(&self) -> Continuity
fn continuity(&self) -> Continuity
How smooth the surface is across its domain.
Source§fn is_closed_u(&self, _tol: Tolerances) -> bool
fn is_closed_u(&self, _tol: Tolerances) -> bool
Whether the surface closes on itself along
u.Source§fn is_closed_v(&self, tol: Tolerances) -> bool
fn is_closed_v(&self, tol: Tolerances) -> bool
Whether the surface closes on itself along
v.Source§fn is_periodic_u(&self) -> bool
fn is_periodic_u(&self) -> bool
Whether
u repeats past the domain.Source§fn is_periodic_v(&self) -> bool
fn is_periodic_v(&self) -> bool
Whether
v repeats past the domain.Source§fn point_d1_at(
&self,
u: f64,
v: f64,
tol: Tolerances,
) -> OgeomResult<(Point, Vector, Vector)>
fn point_d1_at( &self, u: f64, v: f64, tol: Tolerances, ) -> OgeomResult<(Point, Vector, Vector)>
The point and first derivatives together:
(point, du, dv). Read moreSource§fn jet_at(&self, u: f64, v: f64, tol: Tolerances) -> OgeomResult<SurfaceJet>
fn jet_at(&self, u: f64, v: f64, tol: Tolerances) -> OgeomResult<SurfaceJet>
The point and every derivative through second order, together. Read more
Source§fn normal_at(&self, u: f64, v: f64, tol: Tolerances) -> OgeomResult<Direction>
fn normal_at(&self, u: f64, v: f64, tol: Tolerances) -> OgeomResult<Direction>
Source§fn curvature_at(
&self,
u: f64,
v: f64,
tol: Tolerances,
) -> OgeomResult<SurfaceCurvature>
fn curvature_at( &self, u: f64, v: f64, tol: Tolerances, ) -> OgeomResult<SurfaceCurvature>
The principal curvatures and directions at
(u, v). Read moreSource§fn is_degenerate_at(&self, u: f64, v: f64, tol: Tolerances) -> OgeomResult<bool>
fn is_degenerate_at(&self, u: f64, v: f64, tol: Tolerances) -> OgeomResult<bool>
Whether the surface degenerates at
(u, v). Read moreSource§fn normalize_parameters(
&self,
u: f64,
v: f64,
tol: Tolerances,
) -> OgeomResult<(f64, f64)>
fn normalize_parameters( &self, u: f64, v: f64, tol: Tolerances, ) -> OgeomResult<(f64, f64)>
Bring
(u, v) into the domain, wrapping in whichever directions are
periodic, or closed. Read moreSource§fn parameter_outside(
&self,
t: f64,
a: f64,
b: f64,
periodic: bool,
across: bool,
tol: Tolerances,
) -> OgeomResult<f64>
fn parameter_outside( &self, t: f64, a: f64, b: f64, periodic: bool, across: bool, tol: Tolerances, ) -> OgeomResult<f64>
A parameter outside its domain, or on a periodic direction: wrapped
where the direction repeats or closes on itself, refused otherwise. Read more
Auto Trait Implementations§
impl Freeze for RevolutionSurface
impl RefUnwindSafe for RevolutionSurface
impl Send for RevolutionSurface
impl Sync for RevolutionSurface
impl Unpin for RevolutionSurface
impl UnsafeUnpin for RevolutionSurface
impl UnwindSafe for RevolutionSurface
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> Scalar for T
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.