Critical Link MityCam SoC Firmware  1.0
Critical Link MityCam SoC Firmware
ImageGenerator.h
Go to the documentation of this file.
1 #ifndef PATTERNGENERATOR_H
2 #define PATTERNGENERATOR_H
3 
4 #include "CameraTypes.h"
5 #include "ROI.h"
6 #include <vector>
7 #include <map>
8 
9 using namespace SocCamera;
10 
16 {
17 public:
18  tcImageGenerator(const ROI& arROI = ROI(0, 0, 1920, 1080));
20 
21  int setROI(const ROI& arROI);
22  int setPixelFormat(uint32_t anFormat);
23  int setScaler(float scale);
24  uint32_t getScaler(void) const { return mnScaler; }
25 
26  int setTestPattern(teTestPattern aePattern) { meTestPattern = aePattern; return 0; }
27  teTestPattern getTestPattern(void) { return meTestPattern; }
28 
29  int genImage(void* apBuffer, uint32_t anBufLen) const;
30 
31 protected:
32  typedef int (tcImageGenerator::*MFP)(void* apBuffer) const;
33  int GenZeros(void* apBuffer) const;
34  int GenXGrad(void* apBuffer) const;
35  int GenYGrad(void* apBuffer) const;
36 
38  uint32_t mnFormat;
39  float mnScaler;
41  std::map<teTestPattern, MFP> mcGenMap;
42 };
43 
44 
45 #endif // PATTERNGENERATOR_H
tcImageGenerator::getScaler
uint32_t getScaler(void) const
Definition: ImageGenerator.h:24
tcImageGenerator::mcGenMap
std::map< teTestPattern, MFP > mcGenMap
see CameraTypes.h
Definition: ImageGenerator.h:41
SocCamera::teTestPattern
teTestPattern
Definition: CameraTypes.h:122
tcImageGenerator::mcROI
ROI mcROI
our ROI
Definition: ImageGenerator.h:37
tcImageGenerator::mnScaler
float mnScaler
reset to 1.0 if format is changed.
Definition: ImageGenerator.h:39
CameraTypes.h
tcImageGenerator::meTestPattern
teTestPattern meTestPattern
Definition: ImageGenerator.h:40
tcImageGenerator::setTestPattern
int setTestPattern(teTestPattern aePattern)
Definition: ImageGenerator.h:26
SocCamera
Definition: CameraTypes.h:7
tcImageGenerator::mnFormat
uint32_t mnFormat
See RegisterFile.h.
Definition: ImageGenerator.h:38
SocCamera::ROI
Definition: ROI.h:10
tcImageGenerator::getTestPattern
teTestPattern getTestPattern(void)
Definition: ImageGenerator.h:27
tcImageGenerator
Utility class for building image patterns for simulation, etc.
Definition: ImageGenerator.h:15
ROI.h