fix mat copy in shape

fixes #5643
pull/5865/head
Dikay900 9 years ago
parent afdbd855ee
commit bb78b01ace
  1. 6
      modules/shape/src/sc_dis.cpp

@ -124,10 +124,8 @@ public:
virtual void getImages(OutputArray _image1, OutputArray _image2) const virtual void getImages(OutputArray _image1, OutputArray _image2) const
{ {
CV_Assert((!image1.empty()) && (!image2.empty())); CV_Assert((!image1.empty()) && (!image2.empty()));
_image1.create(image1.size(), image1.type()); image1.copyTo(_image1);
_image2.create(image2.size(), image2.type()); image2.copyTo(_image2);
_image1.getMat()=image1;
_image2.getMat()=image2;
} }
virtual void setIterations(int _iterations) {CV_Assert(_iterations>0); iterations=_iterations;} virtual void setIterations(int _iterations) {CV_Assert(_iterations>0); iterations=_iterations;}

Loading…
Cancel
Save