stitcher result mask getter

This commit is contained in:
Quentin Chateau 2018-12-21 23:21:22 +01:00
parent 578ea4bae9
commit f9c951440d
2 changed files with 4 additions and 2 deletions

View File

@ -283,6 +283,7 @@ public:
std::vector<int> component() const { return indices_; }
std::vector<detail::CameraParams> cameras() const { return cameras_; }
CV_WRAP double workScale() const { return work_scale_; }
UMat resultMask() const { return result_mask_; }
private:
Status matchImages();
@ -313,6 +314,7 @@ private:
std::vector<cv::UMat> seam_est_imgs_;
std::vector<int> indices_;
std::vector<detail::CameraParams> cameras_;
UMat result_mask_;
double work_scale_;
double seam_scale_;
double seam_work_aspect_;

View File

@ -357,8 +357,8 @@ Stitcher::Status Stitcher::composePanorama(InputArrayOfArrays images, OutputArra
#if ENABLE_LOG
int64 blend_t = getTickCount();
#endif
UMat result, result_mask;
blender_->blend(result, result_mask);
UMat result;
blender_->blend(result, result_mask_);
LOGLN("blend time: " << ((getTickCount() - blend_t) / getTickFrequency()) << " sec");
LOGLN("Compositing, time: " << ((getTickCount() - t) / getTickFrequency()) << " sec");