Skip to content

Commit 826b77e

Browse files
committed
ximgproc: Fix support for CV_32F WLS Filter
If the disparity maps have the depth CV_32F, they are wls-filtered in `DisparityWLSFilterImpl::filter` but the result is not saved in the OutputArray of the method. Now, the result is copied to that array.
1 parent 6d16876 commit 826b77e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

modules/ximgproc/src/disparity_filters.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -244,6 +244,8 @@ void DisparityWLSFilterImpl::filter(InputArray disparity_map_left, InputArray le
244244
filter_(left, left_view, filt_disp, right, ROI);
245245
if (disparity_map_left.depth() != CV_32F){
246246
filt_disp.convertTo(filtered_disparity_map, disparity_map_left.depth());
247+
} else {
248+
filt_disp.copyTo(filtered_disparity_map);
247249
}
248250
}
249251

0 commit comments

Comments
 (0)