Struct cam_geom::linearize::JacobianPerspectiveCache
source · pub struct JacobianPerspectiveCache<R: RealField> { /* private fields */ }
Expand description
Required data required for finding Jacobian of perspective camera models.
Create this with the new()
method.
Implementations§
source§impl<R: RealField> JacobianPerspectiveCache<R>
impl<R: RealField> JacobianPerspectiveCache<R>
sourcepub fn new(cam: &Camera<R, IntrinsicParametersPerspective<R>>) -> Self
pub fn new(cam: &Camera<R, IntrinsicParametersPerspective<R>>) -> Self
Create a new JacobianPerspectiveCache
from a Camera
with a perspective model.
sourcepub fn linearize_at<STORAGE>(
&self,
p: &Points<WorldFrame, R, U1, STORAGE>
) -> SMatrix<R, 2, 3>
pub fn linearize_at<STORAGE>( &self, p: &Points<WorldFrame, R, U1, STORAGE> ) -> SMatrix<R, 2, 3>
Linearize camera model by evaluating around input point p
.
Returns Jacobian matrix A
(shape 2x3) such that Ao = (u,v)
where o
is 3D world coords offset from p
and (u,v)
are the shift in pixel
coords from the projected location of p
. In other words, for a camera
model F(x)
, if F(p) = (a,b)
and `F(p+o) = (a,b)
- Ao = (a,b) + (u,v) = (a+u,b+v)
, this function returns
A`.
Auto Trait Implementations§
impl<R> Freeze for JacobianPerspectiveCache<R>where
R: Freeze,
impl<R> RefUnwindSafe for JacobianPerspectiveCache<R>where
R: RefUnwindSafe,
impl<R> Send for JacobianPerspectiveCache<R>
impl<R> Sync for JacobianPerspectiveCache<R>
impl<R> Unpin for JacobianPerspectiveCache<R>where
R: Unpin,
impl<R> UnwindSafe for JacobianPerspectiveCache<R>where
R: UnwindSafe,
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> 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>
Converts
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>
Converts
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 moresource§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
source§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 moresource§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).source§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.source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self
to the equivalent element of its superset.