-
Notifications
You must be signed in to change notification settings - Fork 12
/
opencv_viewer_data_publisher.hpp
51 lines (40 loc) · 1.29 KB
/
opencv_viewer_data_publisher.hpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#ifndef SLAM_OPENCV_DATA_PUBLISHER_HPP
#define SLAM_OPENCV_DATA_PUBLISHER_HPP
#include "../slam/viewer_data_publisher.hpp"
#include <opencv2/core.hpp>
namespace slam {
class OpenCVViewerDataPublisher : public ViewerDataPublisher {
public:
OpenCVViewerDataPublisher(const cmd::ParametersSlam ¶meters);
void visualizeKeyframe(
const MapDB &mapDB,
const cv::Mat &frame,
const Keyframe &kf
) final;
void visualizeOrbs(
const cv::Mat &frame,
const Keyframe &kf
) final;
void visualizeMapPointSearch(
const cv::Mat &frame,
const SearchedMapPointVector &searched,
const Vector2dVector &mps,
const Vector2dVector &kps
) final;
void showMatches(
const Keyframe &kf1,
const Keyframe &kf2,
const std::vector<std::pair<KpId, KpId>> &matches,
MatchType matchType
) final;
virtual void visualizeOther(const cv::Mat &mat) final;
std::map<std::string, cv::Mat> pollVisualizations() final;
void setFrameRotation(int rotation) final;
private:
cv::Mat tmpWindow, tmpWindow2, tmpWindow3;
cv::Mat keyframeWindow, matchWindow, matchWindowLoop, searchWindow, otherWindow;
// Number of CW 90 degree rotations for frame visualizations.
int rotation = 0;
};
}
#endif