Page 1 of 1

Transcoded MP4 Duration Not Matching with Source Duration

Posted: Tue Jul 26, 2016 6:55 am
by vijm1972
Hi Steipal,

I am transcoding MXF file to MP4 using command line option, after transcoding I am getting some extra frames in MP4 audio track. I am using below command for transcoding.

ffmpeg.exe -i Test.mxf -c:v libx264 -preset veryslow -crf 18 -s 640x360 -aspect 16:9 -b:v 650000 -minrate 650000 -maxrate 650000 -bufsize 300000 -pix_fmt yuv420p -coder 1 -flags +loop -cmp chroma -partitions +parti8x8+parti4x4+partp8x8+partb8x8 -me_method 4 -subq 6 -me_range 16 -g 15 -keyint_min 1 -bf 0 -intra -refs 4 -sc_threshold 40 -i_qfactor 0.71 -b_strategy 1 -qcomp 0.6 -qmin 10 -qmax 51 -qdiff 4 -direct-pred 1 -fast-pskip 1 -vprofile main -vlevel 4.1 -movflags +faststart -c:a aac -ar 48000 -b:a 128000 -ac 2 Test.mp4

Please find attached screen shot for your reference.
AAC Audio Duration Issue.jpg
AAC Audio Duration Issue.jpg (172.06 KiB) Viewed 7741 times
I have also checked in encoders MP4 option but output is same.

When we play these MP4 files in FCP or Adobe we doesn't observed any issue but when we play them in switch or HTML player we are getting extra frames at the end. Media info also showing extra frames in audio stream.

Please find attached screen shot of Switch player for your reference.

1.jpg
1.jpg (58.87 KiB) Viewed 7741 times

Extra frames at the end.
2.jpg
2.jpg (236.19 KiB) Viewed 7741 times
Can you please suggest if this is an aac codec behavior or some other issue is there.

Regards,
Vijay

Re: Transcoded MP4 Duration Not Matching with Source Duration

Posted: Tue Jul 26, 2016 8:15 am
by admin
Hi Vijay,

Is this issue only apparent when using FFAStrans?

-steinar

Re: Transcoded MP4 Duration Not Matching with Source Duration

Posted: Wed Jul 27, 2016 5:07 am
by vijm1972
No it's happening while using command line too.

Vijay

Re: Transcoded MP4 Duration Not Matching with Source Duration

Posted: Thu Jul 28, 2016 1:10 pm
by donkpow
It's just my opinion but you may want to set fps and use -vsync in that command line. That should access time base during encode.