pub struct Image {
pub image_id: ImageId,
pub name: String,
pub camera_id: CameraId,
pub frame_id: FrameId,
/* private fields */
}Expand description
Image. The pose is not stored but derived from the frame.
Fields§
§image_id: ImageIdImage id.
name: StringMust not contain whitespace (text format delimiter).
camera_id: CameraIdCamera id.
frame_id: FrameIdFrame id it belongs to.
Implementations§
Source§impl Image
impl Image
Sourcepub fn new(
image_id: ImageId,
name: impl Into<String>,
camera_id: CameraId,
points: impl IntoIterator<Item = Vec2>,
) -> Self
pub fn new( image_id: ImageId, name: impl Into<String>, camera_id: CameraId, points: impl IntoIterator<Item = Vec2>, ) -> Self
Creates from 2D point coordinates (no links, frame unassigned).
Sourcepub fn point2d(&self, idx: Point2DIdx) -> &Point2D
pub fn point2d(&self, idx: Point2DIdx) -> &Point2D
The idx-th 2D point.
Sourcepub fn num_points2d(&self) -> usize
pub fn num_points2d(&self) -> usize
Number of 2D points.
Sourcepub fn num_points3d(&self) -> usize
pub fn num_points3d(&self) -> usize
Number of 2D points linked to a 3D point (cached).
Trait Implementations§
impl StructuralPartialEq for Image
Auto Trait Implementations§
impl Freeze for Image
impl RefUnwindSafe for Image
impl Send for Image
impl Sync for Image
impl Unpin for Image
impl UnsafeUnpin for Image
impl UnwindSafe for Image
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,
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<T> Pointable for T
impl<T> Pointable for T
impl<T> Scalar for T
Source§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.