diff --git a/include/hdrplus/burst.h b/include/hdrplus/burst.h index 4dd7eea..941722c 100644 --- a/include/hdrplus/burst.h +++ b/include/hdrplus/burst.h @@ -14,10 +14,8 @@ class burst explicit burst( const std::string& burst_path, const std::string& reference_image_path ); ~burst() = default; - std::string reference_image_path; - std::string burst_path; + // Reference image index in the array int reference_image_idx; - std::vector bayer_image_paths; // Source bayer images & grayscale unpadded image std::vector bayer_images; @@ -25,7 +23,14 @@ class burst // Image padded to tile size // Use for alignment, merging, and finishing std::vector grayscale_images_pad; + + // number of image (including reference) in burst + int num_images; + private: + std::string reference_image_path; + std::string burst_path; + std::vector bayer_image_paths; }; } // namespace hdrplus diff --git a/src/burst.cpp b/src/burst.cpp index d980b51..650e96f 100644 --- a/src/burst.cpp +++ b/src/burst.cpp @@ -12,6 +12,9 @@ burst::burst( const std::string& burst_path, const std::string& reference_image_ // Search through the input path directory to get all input image path cv::glob( burst_path + "/*.dng", bayer_image_paths, false ); + // Number of images + num_images = bayer_image_paths.size(); + // Find reference image path in input directory // reference image path need to be absolute path reference_image_idx = -1;