#[non_exhaustive]pub struct ForstnerConfig {
pub radius: i32,
pub min_trace: f32,
pub min_det: f32,
pub max_condition_number: f32,
pub max_offset: f32,
}Expand description
Configuration for the ForstnerRefiner.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.radius: i32Half-size of the local gradient window, in image pixels (integer
>= 1; the window is (2·radius+1)²). Default 2 gives a 5×5
patch, large enough to capture the gradient structure around a
corner while staying local.
min_trace: f32Minimum trace of the structure tensor (sum of eigenvalues; >= 0,
in squared gradient units). Rejects flat regions with too little
gradient energy; the default 25.0 is roughly a mean gradient
magnitude of 5 per pixel in a 5×5 window.
min_det: f32Minimum determinant of the structure tensor (product of
eigenvalues; >= 0). Guards against singular systems where the
least-squares solution is numerically unstable; the default 1e-3
rejects only truly degenerate cases.
max_condition_number: f32Maximum ratio of the larger to the smaller structure-tensor
eigenvalue (unitless, >= 1). A high ratio indicates an edge
rather than a corner; the default 50.0 is permissive (literature
values span roughly 10–100).
max_offset: f32Maximum displacement from the initial integer seed to the refined
location, in pixels (>= 0). Larger offsets suggest a mislocated
seed and the result is rejected; the default is 1.5.
Trait Implementations§
Source§impl Clone for ForstnerConfig
impl Clone for ForstnerConfig
impl Copy for ForstnerConfig
Source§impl Debug for ForstnerConfig
impl Debug for ForstnerConfig
Source§impl Default for ForstnerConfig
impl Default for ForstnerConfig
Source§impl<'de> Deserialize<'de> for ForstnerConfigwhere
ForstnerConfig: Default,
impl<'de> Deserialize<'de> for ForstnerConfigwhere
ForstnerConfig: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl JsonSchema for ForstnerConfig
impl JsonSchema for ForstnerConfig
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read moreSource§impl PartialEq for ForstnerConfig
impl PartialEq for ForstnerConfig
Source§impl Serialize for ForstnerConfig
impl Serialize for ForstnerConfig
impl StructuralPartialEq for ForstnerConfig
Auto Trait Implementations§
impl Freeze for ForstnerConfig
impl RefUnwindSafe for ForstnerConfig
impl Send for ForstnerConfig
impl Sync for ForstnerConfig
impl Unpin for ForstnerConfig
impl UnsafeUnpin for ForstnerConfig
impl UnwindSafe for ForstnerConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> 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 more