summaryrefslogtreecommitdiff
path: root/libavcodec/tiff.c
diff options
context:
space:
mode:
authorJean First <jeanfirst@gmail.com>2011-09-23 08:22:31 +0200
committerJustin Ruggles <justin.ruggles@gmail.com>2014-04-12 14:49:07 -0400
commitbf2064f046af64c59a416c814474a39b0a457569 (patch)
tree9b7872a299a66a580956e314a4a9ca4a24c5a61e /libavcodec/tiff.c
parentd9a542ace1b9ca5c0ea6d758127d03d4124b7801 (diff)
tiffdec: rename variables for consistency and fix variable shadowing
Signed-off-by: Justin Ruggles <justin.ruggles@gmail.com>
Diffstat (limited to 'libavcodec/tiff.c')
-rw-r--r--libavcodec/tiff.c13
1 files changed, 5 insertions, 8 deletions
diff --git a/libavcodec/tiff.c b/libavcodec/tiff.c
index 7fb0e7a3a6..9f8bc60b48 100644
--- a/libavcodec/tiff.c
+++ b/libavcodec/tiff.c
@@ -665,14 +665,11 @@ static int decode_frame(AVCodecContext *avctx,
}
if (s->invert) {
- uint8_t *src;
- int j;
-
- src = p->data[0];
- for (j = 0; j < s->height; j++) {
- for (i = 0; i < p->linesize[0]; i++)
- src[i] = 255 - src[i];
- src += p->linesize[0];
+ dst = p->data[0];
+ for (i = 0; i < s->height; i++) {
+ for (j = 0; j < p->linesize[0]; j++)
+ dst[j] = 255 - dst[j];
+ dst += stride;
}
}
*got_frame = 1;