mirror of
https://github.com/opencv/opencv.git
synced 2026-09-25 04:09:57 +03:00
photo: drop unnecessary comments
Pre-empting review feedback: keeping the diff minimal, matching how #29597 ended up after review (assert lines with no inline commentary).
This commit is contained in:
@@ -310,9 +310,6 @@ void Domain_Filter::compute_NCfilter(Mat &output, Mat &hz, Mat &psketch, float r
|
||||
int w = output.cols;
|
||||
int channel = output.channels();
|
||||
|
||||
// A single column has no neighbor to convolve across, so leave output
|
||||
// unchanged, matching compute_Rfilter's no-op for w==1. Without this,
|
||||
// the box-filter index math below reads out of bounds. See #29614.
|
||||
if (w < 2)
|
||||
return;
|
||||
|
||||
|
||||
@@ -138,12 +138,6 @@ TEST(Photo_NPR_Stylization, regression)
|
||||
}
|
||||
|
||||
// See https://github.com/opencv/opencv/issues/29614
|
||||
// Domain_Filter::compute_NCfilter (npr.hpp) indexes a summed-area-table
|
||||
// buffer using arithmetic that goes out of bounds when the matrix passed to
|
||||
// it has a single column. cv::stylization always uses NORMCONV_FILTER, so a
|
||||
// single-column source triggers this directly; a single-row source triggers
|
||||
// the same bug through the internal transposed pass. cv::edgePreservingFilter
|
||||
// reaches the identical code path when called with NORMCONV_FILTER.
|
||||
TEST(Photo_NPR_Stylization, degenerate_dimension_29614)
|
||||
{
|
||||
Mat colSrc(5, 1, CV_8UC3, Scalar(100, 150, 200));
|
||||
|
||||
Reference in New Issue
Block a user