Commit 8a21726a authored by Seon-Wook Park's avatar Seon-Wook Park

spatialGradient: Remove an unnecessary branch in nosse code

parent febd0f14
......@@ -301,9 +301,7 @@ void spatialGradient( InputArray _src, OutputArray _dx, OutputArray _dy,
for ( ; j < W; j++ )
{
j_p = j - 1;
j_n = j + 1;
if ( j_p < 0 ) j_p = j + j_offl;
if ( j_n >= W ) j_n = j + j_offr;
// Get values for next column
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment