mltframework / mltframework/mlt

transition tag causes x264 field order confusion

Open
#575 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
1.9k
Forks
387
Avg merge
17h 28m
Merged PRs (30d)
8

Description

I have got some difficulty to render a movie (1080i25, top field first) with the correct field order using melt version 6.21.0 from the kdenlive-20.04.0b-x86_64.appimage. The mlt script used to render the movie was generated by kdenlive 20.04.0.
When I check the field order of the rendered file using
ffprobe -show_frames output.ts | grep top
I can see that the field order in the mpegts container is indicated as top field first, but the actual x264 video stream is bottom field first. However the output should be rendered using top field first, as specified in the consumer tag using x264opts="tff=1" and top_field_first="1".

I have found out that when I delete the transition tags from the mlt script, the movie is rendered using the correct field order. I think that it is bug that a transition tag affects the field order and leads to a mismatch between the field order in the mpegts container and the x264 video stream. Could you please fix this?

I have attached the original script and the one with transition tags removed.
mltscripts.zip
To reproduce the issue, you need to download the H.264 1080i/25.000 (MKV) sample from https://kodi.wiki/view/Samples

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the issue with the attached MLT scripts, the H.264 1080i/25.000 sample, and the stated melt command, comparing renders with and without transition tags. Inspect the transition-related processing and verify completion by confirming that both the MPEG-TS container and the x264 stream report top-field-first output.

Written by the indexing model from the issue text.

Assessment

Domain
audio-video-rtc
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.