pub enum BezierTriangleRefusal {
Degree {
degree: usize,
},
PointCount {
degree: usize,
expected: usize,
found: usize,
},
NonFinite {
index: usize,
},
Magnitude {
index: usize,
},
Weight {
index: usize,
weight: f64,
},
WeightRatio {
min: f64,
max: f64,
},
PoleOutside {
a: f64,
b: f64,
c: f64,
weight: f64,
},
Barycentric {
a: f64,
b: f64,
c: f64,
},
Direction {
da: f64,
db: f64,
dc: f64,
},
Conversion {
reason: String,
},
}Expand description
Why a triangle patch or one of its operations was refused.
Variants§
Degree
Degree zero or above [MAX_TRIANGLE_DEGREE].
PointCount
The control net does not have (n+1)(n+2)/2 points.
NonFinite
A control point or weight that is not finite.
Magnitude
A control point farther than [MAX_TRIANGLE_COORDINATE] from the origin: the
derivative arithmetic would overflow.
Weight
A weight that is not positive: the rational patch would have a pole or change sign inside the domain.
WeightRatio
The smallest weight is below [MIN_WEIGHT_RATIO] of the largest: the
converted tensor net could not hold it.
PoleOutside
The homogeneous weight vanishes or is negative at a point outside the triangle (inside it every weight is a positive convex combination).
Barycentric
Barycentric coordinates that are not finite or do not sum to one.
Direction
A direction whose barycentric components do not sum to zero.
Conversion
The tensor patch builder refused the converted net.
Trait Implementations§
Source§impl Clone for BezierTriangleRefusal
impl Clone for BezierTriangleRefusal
Source§impl Debug for BezierTriangleRefusal
impl Debug for BezierTriangleRefusal
Source§impl Display for BezierTriangleRefusal
impl Display for BezierTriangleRefusal
Source§impl Error for BezierTriangleRefusal
impl Error for BezierTriangleRefusal
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()