[FFmpeg-trac] #9320(undetermined:new): mpeg2video can't be TFF with progressive source
FFmpeg
trac at avcodec.org
Tue Jul 27 21:51:15 EEST 2021
#9320: mpeg2video can't be TFF with progressive source
-------------------------------------+-------------------------------------
Reporter: Paul | Owner: (none)
Pacifico |
Type: defect | Status: new
Priority: normal | Component:
| undetermined
Version: git-master | Resolution:
Keywords: mpeg2video | Blocked By:
Blocking: | Reproduced by developer: 0
Analyzed by developer: 0 |
-------------------------------------+-------------------------------------
Comment (by jeeb):
Alright, that's unfortunate. Then the only remaining block that was moved
in my commits which improved ffmpeg.c's passing of input frame metadata
was the following. You may test with it removed, but I would be surprised
if that would change the result:
{{{
diff --git a/fftools/ffmpeg.c b/fftools/ffmpeg.c
index b0ce7c7c32..45949202a7 100644
--- a/fftools/ffmpeg.c
+++ b/fftools/ffmpeg.c
@@ -3485,10 +3485,6 @@ static int init_output_stream_encode(OutputStream
*ost, AVFrame *frame)
// Field order: autodetection
if (frame) {
- if (enc_ctx->flags & (AV_CODEC_FLAG_INTERLACED_DCT |
AV_CODEC_FLAG_INTERLACED_ME) &&
- ost->top_field_first >= 0)
- frame->top_field_first = !!ost->top_field_first;
-
if (frame->interlaced_frame) {
if (enc_ctx->codec->id == AV_CODEC_ID_MJPEG)
enc_ctx->field_order = frame->top_field_first ?
AV_FIELD_TT:AV_FIELD_BB;
}}}
Otherwise, the issue would have to be [https://git-scm.com/docs/git-bisect
bisected], although unfortunately one would have to apply the `-top` fix
on top when testing commits after my ffmpeg.c rework set.
As a silver lining, at the very least specifically utilizing `setfield`
video filter does lead to the right result thanks to that autodetection
based on input frame metadata I added :) .
--
Ticket URL: <https://trac.ffmpeg.org/ticket/9320#comment:12>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list