#pragma once #include #include #include // std::pair #include // std::shared_ptr #include // all opencv header #include namespace hdrplus { class MemFile { public: std::vector content; const std::vector GetConstData() const { return content; } std::vector GetData() { return content; } }; class bayer_image { public: explicit bayer_image( const std::string& bayer_image_path ); explicit bayer_image( const std::vector& bayer_image_content ); explicit bayer_image( std::shared_ptr bayer_image_file ); ~bayer_image() = default; std::pair get_noise_params() const; std::shared_ptr libraw_processor; cv::Mat raw_image; cv::Mat grayscale_image; int width; int height; int white_level; std::vector black_level_per_channel; float iso; private: float baseline_lambda_shot = 3.24 * pow( 10, -4 ); float baseline_lambda_read = 4.3 * pow( 10, -6 ); }; } // namespace hdrplus