aboutsummaryrefslogtreecommitdiffstats
path: root/meowpp/gra/BundleAdjustment.h
blob: 13fe0b107c2cd34f6cb53b8e3226c5b271e99d39 (plain) (blame)
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
52
53
54
#ifndef   BundleAdjustment_H__
#define   BundleAdjustment_H__

#include "Eye.h"

#include "../oo/ObjBase.h"

namespace meow {

enum SceneInfoFlags {
  CAN_OFFSET = 0x01,
  CAN_ROTATE = 0x02,
  CAN_ZOOM   = 0x04
};

template<class Pixel>
struct SceneInfo {
  Eye<Pixel>*    eye;
  unsigned long flag;

  SceneInfo(): eye(NULL), flag(0) {
  }

  SceneInfo(Eye<Pixel>* e, unsigned long f): eye(e), flag(f) {
  }

  SceneInfo(SceneInfo const& si): eye(si.eye), flag(si.flag) {
  }

  ~SceneInfo() {
  }
};

template<class Pixel>
class BundleAdjustment: public ObjBase {
protected:
  BundleAdjustment() {
  }
public:
  virtual ~BundleAdjustment() {
  }

  virtual bool adjustEye(std::vector<SceneInfo<Pixel> >* seq) const {
    return false;
  }

  virtual bool adjustFixedPoint(std::vector<SceneInfo<Pixel> >* seq) const {
    return false;
  }
};

} // meow

#endif // BundleAdjustment_H__