ClassFlowTakeImage.h 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. #pragma once
  2. #ifndef CLASSFFLOWTAKEIMAGE_H
  3. #define CLASSFFLOWTAKEIMAGE_H
  4. #include "ClassFlowImage.h"
  5. #include "ClassControllCamera.h"
  6. #include "../../include/defines.h"
  7. #include <string>
  8. class ClassFlowTakeImage :
  9. public ClassFlowImage
  10. {
  11. protected:
  12. float waitbeforepicture;
  13. float waitbeforepicture_store;
  14. framesize_t ImageSize;
  15. bool isImageSize;
  16. bool ZoomEnabled = false;
  17. int ZoomMode = 0;
  18. int zoomOffsetX = 0;
  19. int zoomOffsetY = 0;
  20. bool ImageGrayscale;
  21. int ImageQuality;
  22. time_t TimeImageTaken;
  23. string namerawimage;
  24. int image_height, image_width;
  25. bool SaveAllFiles;
  26. bool FixedExposure;
  27. void CopyFile(string input, string output);
  28. esp_err_t camera_capture();
  29. void takePictureWithFlash(int flash_duration);
  30. void SetInitialParameter(void);
  31. public:
  32. CImageBasis *rawImage;
  33. ClassFlowTakeImage(std::vector<ClassFlow*>* lfc);
  34. bool ReadParameter(FILE* pfile, string& aktparamgraph);
  35. bool doFlow(string time);
  36. string getHTMLSingleStep(string host);
  37. time_t getTimeImageTaken();
  38. string name(){return "ClassFlowTakeImage";};
  39. ImageData* SendRawImage();
  40. esp_err_t SendRawJPG(httpd_req_t *req);
  41. ~ClassFlowTakeImage(void);
  42. };
  43. #endif //CLASSFFLOWTAKEIMAGE_H