ifw-fgf 1.0.0-pre1
Loading...
Searching...
No Matches
rawImage.hpp
Go to the documentation of this file.
1
7#ifndef FGF_COM_RAWIMAGE_HPP_H_
8#define FGF_COM_RAWIMAGE_HPP_H_
9
10#define BOOST_BIND_NO_PLACEHOLDERS
11
12namespace ifw::fgf::common {
13
20 class RawImage {
21
22 public:
28 RawImage(int width, int height, int bpp);
29 RawImage(int width, int height, int bpp, unsigned char* image);
30
31 // Disable copy constructor and assignment
32 RawImage(const RawImage&) = delete;
34 virtual ~RawImage();
35
37 int GetWidth();
38
40 int GetHeight();
41
43 int GetBpp();
44
50 int GetSize();
51
57 unsigned char* GetImage();
58
59 double GetTimestamp();
60
61 void SetTimestamp(const double& timestamp);
62
63 private:
64 bool m_wrapper{false};
65 int m_width{0};
66 int m_height{0};
67 double m_timestamp{0};
68
69 // Bytes per pixel will be deduced from the data type
70 int m_bpp{0};
71 int m_sample{0};
72 unsigned char* m_image{nullptr};
73
74 };
75
76}
77
78#endif // FGF_COM_RAWIMAGE_HPP_H_
Raw Image Class to handle one image in memory.
Definition rawImage.hpp:20
int GetBpp()
Get image bytes per pixel.
Definition rawImage.cpp:39
double GetTimestamp()
Definition rawImage.cpp:51
int GetHeight()
Get image height.
Definition rawImage.cpp:35
int GetSize()
Get image size.
Definition rawImage.cpp:43
unsigned char * GetImage()
Get a pointer to the image data.
Definition rawImage.cpp:47
RawImage(const RawImage &)=delete
RawImage & operator=(RawImage &)=delete
int GetWidth()
Get image width.
Definition rawImage.cpp:31
RawImage(int width, int height, int bpp)
Constructor.
Definition rawImage.cpp:10
void SetTimestamp(const double &timestamp)
Definition rawImage.cpp:55
virtual ~RawImage()
Definition rawImage.cpp:25
Frame Grabber Camera Base Class definitions.
Definition binarySemaphore.hpp:43