[PATCH] Re: [Ffmpeg-devel] FFmpeg: H.264 decoding issue

Matthias Hopf mat
Wed Feb 21 14:44:12 CET 2007


On Feb 21, 07 13:53:29 +0100, Matthias Hopf wrote:
> The other solution would be something like
> 
> 	if (s->picture_structure==PICT_FRAME) {
> 	  draw_edges(s->current_picture.data[0], s->linesize, s->h_edge_pos, s->v_edge_pos, EDGE_WIDTH);
> 	  [...]
> 	} else {
> 	  int o = (s->picutre_structure==PICT_BOTTOM_FIELD ? s->current_picture.linesize[i]/2 : 0);
> 	  draw_edges(s->current_picture.data[0], s->linesize, s->h_edge_pos, s->v_edge_pos, EDGE_WIDTH);

That should read
          draw_edges(s->current_picture.data[0]-o, s->linesize, s->h_edge_pos, s->v_edge_pos, EDGE_WIDTH);

> 	  [...]
> 	}
> 
> Yes, this is dead ugly and potentially harmful, with its broken mixture
> of current_picuture and MpegEncContext accesses.

Matthias

-- 
Matthias Hopf <mhopf at suse.de>      __        __   __
Maxfeldstr. 5 / 90409 Nuernberg   (_   | |  (_   |__          mat at mshopf.de
Phone +49-911-74053-715           __)  |_|  __)  |__  R & D   www.mshopf.de




More information about the ffmpeg-devel mailing list