IOLink  IOL_v1.2.0_release
ImageProperties.h
1 #pragma once
2 
3 #include <memory>
4 
5 #include <iolink/IOLinkAPI.h>
6 #include <iolink/property/ImageInfoProperty.h>
7 #include <iolink/property/SpatialCalibrationProperty.h>
8 
9 namespace iolink
10 {
11 
15 class IOLINK_API ImageProperties
16 {
17 public:
21  static std::shared_ptr<ImageProperties> fromDataType(DataType dataType);
22 
30  static std::shared_ptr<ImageProperties> fromProperties(const SpatialCalibrationProperty& calibration,
31  const ImageInfoProperty& imageInfo);
32 
36  static std::shared_ptr<ImageProperties> fromProperties(std::shared_ptr<const ImageProperties> properties,
37  const SpatialCalibrationProperty& calibration);
38 
42  static std::shared_ptr<ImageProperties> fromProperties(std::shared_ptr<const ImageProperties> properties,
43  const ImageInfoProperty& imageInfo);
44 
50  ImageProperties(const SpatialCalibrationProperty& calibration, const ImageInfoProperty& imageInfo);
51 
52  ImageProperties(const ImageProperties& other);
53  ImageProperties& operator=(const ImageProperties& other);
54 
55  ImageProperties(ImageProperties&& other) noexcept;
56  ImageProperties& operator=(ImageProperties&& other) noexcept;
57 
61  std::string toString() const;
62 
63  ~ImageProperties();
64 
68  std::shared_ptr<ImageProperties> clone() const;
69 
75  const SpatialCalibrationProperty& calibration() const;
76 
82  const ImageInfoProperty& imageInfo() const;
83 
87  SpatialCalibrationProperty& calibration();
88 
92  ImageInfoProperty& imageInfo();
93 
100  bool isCompatibleWith(const VectorXu64& shape, DataType type) const;
101 
105  bool operator==(const ImageProperties& other) const;
106 
107 private:
108  class Private;
109  Private* m_private;
110 };
111 
112 } // end namespace iolink