LOST  0.0.1
LOST: Open-source Star Tracker
centroiders.hpp
Go to the documentation of this file.
1 #ifndef CENTROID_H
2 #define CENTROID_H
3 
4 #include <iostream>
5 #include <vector>
6 
7 #include "star-utils.hpp"
8 
9 namespace lost {
10 
13 public:
19  virtual Stars Go(unsigned char *image, int imageWidth, int imageHeight) const = 0;
20 
21  virtual ~CentroidAlgorithm() { };
22 };
23 
26 public:
27  explicit DummyCentroidAlgorithm(int numStars) : numStars(numStars) { };
28  Stars Go(unsigned char *image, int imageWidth, int imageHeight) const override;
29 private:
30  int numStars;
31 };
32 
38 public:
40  Stars Go(unsigned char *image, int imageWidth, int imageHeight) const override;
41 };
42 
48  public:
50  Stars Go(unsigned char *image, int imageWidth, int imageHeight) const override;
51 };
52 
53 }
54 
55 #endif
A simple, fast, and pretty decent centroid algorithm.
Definition: centroiders.hpp:37
Stars Go(unsigned char *image, int imageWidth, int imageHeight) const override
Actually perform the centroid detection.
An algorithm that detects the (x,y) coordinates of bright points in an image, called "centroids".
Definition: centroiders.hpp:12
virtual Stars Go(unsigned char *image, int imageWidth, int imageHeight) const =0
Actually perform the centroid detection.
A centroid algorithm for debugging that returns random centroids.
Definition: centroiders.hpp:25
Stars Go(unsigned char *image, int imageWidth, int imageHeight) const override
Actually perform the centroid detection.
Definition: centroiders.cpp:19
DummyCentroidAlgorithm(int numStars)
Definition: centroiders.hpp:27
A more complicated centroid algorithm which doesn't perform much better than CenterOfGravityAlgorithm...
Definition: centroiders.hpp:47
Stars Go(unsigned char *image, int imageWidth, int imageHeight) const override
Actually perform the centroid detection.
LOST starting point.
std::vector< Star > Stars
Definition: star-utils.hpp:101