pub struct GlobalTransformEstimate {
pub transform: AffineTransform2D,
pub confidence: f32,
pub method: TransformEstimationMethod,
pub computed_at: ViewVersion,
}Expand description
A frame-to-reference coordinate transform estimate.
Provided by ViewStateProvider implementations that perform
feature matching, optical flow, or PTZ-based modeling.
Fields§
§transform: AffineTransform2DThe affine transform from current frame coordinates to reference coordinates.
confidence: f32Confidence in this estimate, in [0.0, 1.0].
method: TransformEstimationMethodMethod used to compute this transform.
computed_at: ViewVersionViewVersion at which this transform was computed.
Consumers can compare against the current version to detect staleness.
Implementations§
Source§impl GlobalTransformEstimate
impl GlobalTransformEstimate
Sourcepub fn displacement_magnitude(&self) -> f32
pub fn displacement_magnitude(&self) -> f32
Displacement magnitude (in normalized coordinates) implied by the translation component of the transform.
sqrt(tx² + ty²) of the affine matrix.
Trait Implementations§
Source§impl Clone for GlobalTransformEstimate
impl Clone for GlobalTransformEstimate
Source§fn clone(&self) -> GlobalTransformEstimate
fn clone(&self) -> GlobalTransformEstimate
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for GlobalTransformEstimate
impl Debug for GlobalTransformEstimate
Source§impl PartialEq for GlobalTransformEstimate
impl PartialEq for GlobalTransformEstimate
impl StructuralPartialEq for GlobalTransformEstimate
Auto Trait Implementations§
impl Freeze for GlobalTransformEstimate
impl RefUnwindSafe for GlobalTransformEstimate
impl Send for GlobalTransformEstimate
impl Sync for GlobalTransformEstimate
impl Unpin for GlobalTransformEstimate
impl UnsafeUnpin for GlobalTransformEstimate
impl UnwindSafe for GlobalTransformEstimate
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