[FFmpeg-cvslog] r20488 - trunk/libavfilter/vf_crop.c
stefano
subversion
Mon Nov 9 22:00:39 CET 2009
Author: stefano
Date: Mon Nov 9 22:00:38 2009
New Revision: 20488
Log:
Fix crop filter start_frame() for paletted formats different from
PAL8. Shift data[1] only if the input format is not paletted.
Modified:
trunk/libavfilter/vf_crop.c
Modified: trunk/libavfilter/vf_crop.c
==============================================================================
--- trunk/libavfilter/vf_crop.c Mon Nov 9 19:56:51 2009 (r20487)
+++ trunk/libavfilter/vf_crop.c Mon Nov 9 22:00:38 2009 (r20488)
@@ -176,7 +176,11 @@ static void start_frame(AVFilterLink *li
ref2->data[0] += crop->y * ref2->linesize[0];
ref2->data[0] += (crop->x * crop->bpp) >> 3;
- if (link->format != PIX_FMT_PAL8) {
+ if (link->format != PIX_FMT_PAL8 &&
+ link->format != PIX_FMT_BGR4_BYTE &&
+ link->format != PIX_FMT_RGB4_BYTE &&
+ link->format != PIX_FMT_BGR8 &&
+ link->format != PIX_FMT_RGB8) {
for (i = 1; i < 3; i ++) {
if (ref2->data[i]) {
ref2->data[i] += (crop->y >> crop->vsub) * ref2->linesize[i];
More information about the ffmpeg-cvslog
mailing list