33#include " BaseAlembicObject.hpp"
44#include < aliceVision/sfmData/SfMData.hpp>
55
6+ using namespace aliceVision ;
67
78namespace abcentity
89{
910
10- struct LandmarkPerView ;
11+ /* *
12+ * @brief encapsulates sufficient and fast retrievable information on a landmark observed by a view
13+ */
14+ struct LandmarkPerView
15+ {
16+ LandmarkPerView () = default ;
17+
18+ LandmarkPerView (const IndexT& landmarkId, const sfmData::Landmark& landmark,
19+ const sfmData::Observation& observation)
20+ : landmarkId(landmarkId)
21+ , landmark(landmark)
22+ , observation(observation)
23+ {
24+ }
25+
26+ const uint& landmarkId;
27+ const sfmData::Landmark& landmark;
28+ const sfmData::Observation& observation;
29+ };
1130
1231class ObservationsEntity : public BaseAlembicObject
1332{
@@ -18,7 +37,7 @@ class ObservationsEntity : public BaseAlembicObject
1837 ~ObservationsEntity () override = default ;
1938
2039 void setData ();
21- void update (const aliceVision:: IndexT& viewId, const QVariantMap& viewer2DInfo);
40+ void update (const IndexT& viewId, const QVariantMap& viewer2DInfo);
2241
2342private:
2443
@@ -34,12 +53,12 @@ class ObservationsEntity : public BaseAlembicObject
3453 // in _indexBytesByLandmark for a landmark
3554 std::vector<std::pair<uint, uint>> _landmarkId2IndexRange;
3655 // maps view id to index of the corresponding position for a view camera in position data
37- std::map<aliceVision:: IndexT, uint> _viewId2vertexPos;
38- aliceVision:: sfmData::SfMData _sfmData;
56+ std::map<IndexT, uint> _viewId2vertexPos;
57+ sfmData::SfMData _sfmData;
3958 // maps view id to a pair containing:
4059 // - the total number of observations of all landmarks observed by this view
4160 // - a vector of LandmarkPerView structures corresponding to the landmarks observed by this view
42- stl::flat_map<aliceVision:: IndexT, std::pair<size_t , std::vector<LandmarkPerView>>> _landmarksPerView;
61+ stl::flat_map<IndexT, std::pair<size_t , std::vector<LandmarkPerView>>> _landmarksPerView;
4362};
4463
4564} // namespace
0 commit comments