spatialGradient: Remove unnecessary index calculation
This commit is contained in:
parent
b5c4355c13
commit
815cd8970d
@ -220,7 +220,6 @@ void spatialGradient( InputArray _src, OutputArray _dx, OutputArray _dy, int ksi
|
||||
for ( i = 1; i < H - 1; i++ )
|
||||
{
|
||||
// Load last row for 3x3 Sobel filter
|
||||
idx = i*W + j;
|
||||
v_um = v_load(&p_src[idx + W - 1]);
|
||||
v_un = v_load(&p_src[idx + W]);
|
||||
v_up = v_load(&p_src[idx + W + 1]);
|
||||
@ -261,6 +260,8 @@ void spatialGradient( InputArray _src, OutputArray _dx, OutputArray _dy, int ksi
|
||||
v_snn2 = v_spn2;
|
||||
v_snp1 = v_spp1;
|
||||
v_snp2 = v_spp2;
|
||||
|
||||
idx += W;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -602,7 +602,6 @@ void CV_SpatialGradientTest::run_func()
|
||||
test_mat[OUTPUT][1] = dy;
|
||||
}
|
||||
|
||||
|
||||
void CV_SpatialGradientTest::prepare_to_validation( int /*test_case_idx*/ )
|
||||
{
|
||||
int dx, dy;
|
||||
|
Loading…
x
Reference in New Issue
Block a user