Package boofcv.abst.geo.bundle
Class SceneObservations.View
java.lang.Object
boofcv.abst.geo.bundle.SceneObservations.View
- Enclosing class:
- SceneObservations
-
Field Summary
Modifier and TypeFieldDescription@Nullable BundleCameraState
Camera's state when this view was observed.Pixel observations of features in 'point' in an interleaved format (x,y)list of Point ID's that are visible in this view. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
add
(int featureIndex, float x, float y) Adds an observation of the specified feature.void
void
getPixel
(int index, PointIndex2D_F64 observation) void
getPixel
(int index, Point2D_F64 p) int
getPointId
(int index) boolean
void
remove
(int index) Removes the feature and observation at the specified elementvoid
reset()
Puts it back into its original state.void
resize
(int numPoints) void
safeAssignToFeature
(int index, int featureIdx) Assigns this observation to th specified feature.void
set
(int index, int featureIdx, float x, float y) Sets the feature Id and observation for an observationvoid
setPixel
(int index, float x, float y) int
size()
-
Field Details
-
point
list of Point ID's that are visible in this view. -1 indicates the point has been removed -
observations
Pixel observations of features in 'point' in an interleaved format (x,y) -
cameraState
Camera's state when this view was observed. E.g. focal length / zoom
-
-
Constructor Details
-
View
public View()
-
-
Method Details
-
size
public int size() -
remove
public void remove(int index) Removes the feature and observation at the specified element -
safeAssignToFeature
public void safeAssignToFeature(int index, int featureIdx) Assigns this observation to th specified feature. Does sanity checks to make sure everything is consistent. -
set
public void set(int index, int featureIdx, float x, float y) Sets the feature Id and observation for an observation- Parameters:
index
- Which observation to setfeatureIdx
- The feature which was observedx
- observation x-axisy
- observation y-axis
-
setPixel
public void setPixel(int index, float x, float y) -
getPointId
public int getPointId(int index) -
getPixel
-
getPixel
-
add
public void add(int featureIndex, float x, float y) Adds an observation of the specified feature.NOTE: For rigid body features you need to add the offset for the specific rigid object to the internal index. You should call
SceneStructureMetric.Rigid.connectPointToView(int, int, float, float, SceneObservations)
instead- Parameters:
featureIndex
- Feature indexx
- pixel x-coordinatey
- pixel y-coordinate
-
checkDuplicatePoints
public void checkDuplicatePoints() -
reset
public void reset()Puts it back into its original state. -
resize
public void resize(int numPoints) -
isIdentical
-