[FFmpeg-devel] [PATCH]Do not set bitrate for DTS-HD Master and High Resolution

Michael Niedermayer michaelni at gmx.at
Wed Mar 18 13:06:06 CET 2015


On Wed, Mar 18, 2015 at 07:49:46AM -0400, Marcus Johnson wrote:
> This reminds me of another bug with DTS files, it estimates the file
> duration by counting each frame I assume, including the HD ones resulting
> in it being massively incorrect for example here's the ffmpeg output of a
> DTS-HD MA file that's actually 98 minutes long
> 
> 
> 
> Log:
> 
> ffmpeg -i /Users/Marcus/Desktop/DTS/ThePrincessBride.dtsma
> 
> ffmpeg version N-68833-ge949e9f Copyright (c) 2000-2014 the FFmpeg
> developers
> 
>   built on Mar 18 2015 07:47:46 with Apple LLVM version 6.0
> (clang-600.0.57) (based on LLVM 3.5svn)
> 
>   configuration: --disable-yasm --disable-asm --disable-inline-asm
> --disable-ffserver --disable-ffplay --disable-doc --disable-ffprobe
> 
>   libavutil      54. 16.100 / 54. 16.100
> 
>   libavcodec     56. 19.100 / 56. 19.100
> 
>   libavformat    56. 16.102 / 56. 16.102
> 
>   libavdevice    56.  3.100 / 56.  3.100
> 
>   libavfilter     5.  6.100 /  5.  6.100
> 
>   libswscale      3.  1.101 /  3.  1.101
> 
>   libswresample   1.  1.100 /  1.  1.100
> 
> [dts @ 0x7fe833822800] Estimating duration from bitrate, this may be
> inaccurate
> 
> Input #0, dts, from '/Users/Marcus/Desktop/DTS/ThePrincessBride.dtsma':
> 
>   Duration: 04:06:57.61, start: 0.000000, bitrate: 1535 kb/s
> 
>     Stream #0:0: Audio: dts (DTS), 48000 Hz, 5.1(side), fltp, 1536 kb/s
> 
> 
> Instead of it saying it's about 1 hours and 30 minutes, it says it's 4
> hours, and 6 minutes.
> 
> 

> Maybe the parser should ignore the dts-hd frames, because they won't
> increase the duration at all, due to the differential nature of the codec.

if i understand correctly, yes,

all parts of the data stream which encode the same time period belong
in the same AVPacket.
Like also with video frames parts that encode slices or more details
of a picture should be all in the same AVPacket, that way a decoder
takes a AVPacket and can return a picture or sequence of audio samples
also each AVPackets duration can be added up (thats slightly
oversimplified for overlapped transforms and stuff)
but storing additional details in a seperate AVPacket which cover
the same time period as the last packet isnt supported currently and
would cause problems


[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Awnsering whenever a program halts or runs forever is
On a turing machine, in general impossible (turings halting problem).
On any real computer, always possible as a real computer has a finite number
of states N, and will either halt in less than N cycles or never halt.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20150318/f90c35cf/attachment.asc>


More information about the ffmpeg-devel mailing list