Commit 07983b25 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Sharpen: use local variables for loops

parent d71c794d
...@@ -170,7 +170,6 @@ static void Destroy( vlc_object_t *p_this ) ...@@ -170,7 +170,6 @@ static void Destroy( vlc_object_t *p_this )
static picture_t *Filter( filter_t *p_filter, picture_t *p_pic ) static picture_t *Filter( filter_t *p_filter, picture_t *p_pic )
{ {
picture_t *p_outpic; picture_t *p_outpic;
int i, j;
uint8_t *restrict p_src = NULL; uint8_t *restrict p_src = NULL;
uint8_t *restrict p_out = NULL; uint8_t *restrict p_out = NULL;
int i_src_pitch; int i_src_pitch;
...@@ -202,11 +201,11 @@ static picture_t *Filter( filter_t *p_filter, picture_t *p_pic ) ...@@ -202,11 +201,11 @@ static picture_t *Filter( filter_t *p_filter, picture_t *p_pic )
memcpy(p_out, p_src, i_visible_pitch); memcpy(p_out, p_src, i_visible_pitch);
for( i = 1; i < i_visible_lines - 1; i++ ) for( unsigned i = 1; i < i_visible_lines - 1; i++ )
{ {
p_out[i * i_out_pitch] = p_src[i * i_src_pitch]; p_out[i * i_out_pitch] = p_src[i * i_src_pitch];
for( j = 1; j < i_visible_pitch - 1; j++ ) for( unsigned j = 1; j < i_visible_pitch - 1; j++ )
{ {
pix = (p_src[(i - 1) * i_src_pitch + j - 1] * v1) + pix = (p_src[(i - 1) * i_src_pitch + j - 1] * v1) +
(p_src[(i - 1) * i_src_pitch + j ] * v1) + (p_src[(i - 1) * i_src_pitch + j ] * v1) +
......
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