dec: remove interlaced update code

This commit is contained in:
Wim Taymans 2011-10-03 11:34:34 +02:00
parent d4b2751c39
commit 3b230ce9b6

View file

@ -1880,8 +1880,7 @@ gst_ffmpegdec_video_frame (GstFFMpegDec * ffmpegdec,
ffmpegdec->ctx_interlaced = ffmpegdec->picture->interlaced_frame; ffmpegdec->ctx_interlaced = ffmpegdec->picture->interlaced_frame;
gst_ffmpegdec_video_negotiate (ffmpegdec, TRUE); gst_ffmpegdec_video_negotiate (ffmpegdec, TRUE);
} }
#if 0
/* Whether a frame is interlaced or not is unknown at the time of /* Whether a frame is interlaced or not is unknown at the time of
buffer allocation, so caps on the buffer in opaque will have buffer allocation, so caps on the buffer in opaque will have
the previous frame's interlaced flag set. So if interlacedness the previous frame's interlaced flag set. So if interlacedness
@ -1893,7 +1892,7 @@ gst_ffmpegdec_video_frame (GstFFMpegDec * ffmpegdec,
GstStructure *s = gst_caps_get_structure (GST_BUFFER_CAPS (buffer), 0); GstStructure *s = gst_caps_get_structure (GST_BUFFER_CAPS (buffer), 0);
gboolean interlaced; gboolean interlaced;
gboolean found = gst_structure_get_boolean (s, "interlaced", &interlaced); gboolean found = gst_structure_get_boolean (s, "interlaced", &interlaced);
if (!found || (!!interlaced != !!ffmpegdec->format.video.interlaced)) { if (!found || (! !interlaced != ! !ffmpegdec->format.video.interlaced)) {
GST_DEBUG_OBJECT (ffmpegdec, GST_DEBUG_OBJECT (ffmpegdec,
"Buffer interlacing does not match pad, updating"); "Buffer interlacing does not match pad, updating");
buffer = gst_buffer_make_metadata_writable (buffer); buffer = gst_buffer_make_metadata_writable (buffer);
@ -1902,6 +1901,7 @@ gst_ffmpegdec_video_frame (GstFFMpegDec * ffmpegdec,
} }
} }
} }
#endif
/* check if we are dealing with a keyframe here, this will also check if we /* check if we are dealing with a keyframe here, this will also check if we
* are dealing with B frames. */ * are dealing with B frames. */