diff options
author | Anton Khirnov <anton@khirnov.net> | 2023-04-24 16:47:50 +0200 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2023-05-02 10:57:21 +0200 |
commit | 0ed1eeb74435c6d10edd251ce3529fce8ea564d6 (patch) | |
tree | 86bf6f3dc9fee4970ac3e317ee893f51cf31f9b1 /libavcodec | |
parent | aae5ba31ca94307c15e134d98e7492cf5a208426 (diff) | |
download | ffmpeg-0ed1eeb74435c6d10edd251ce3529fce8ea564d6.tar.gz |
lavf/dv: use a more granular timebase for audio
One that is fine enough to represent all DV audio sample rates. Audio
packet durations are now sample-accurate.
This largely undoes commit 76fbb0052df471075858c1cb82b04c8be7adba8d. To
avoid breaking the issue fixed by that commit, resync audio timestamps
against video if they get more than one frame apart. The sample from
issue #8762 still works correctly after this commit.
Slightly changes the results of the lavf-dv seektest, due to the audio
timebase being more granular.
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/dv.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/dv.h b/libavcodec/dv.h index b473bdc992..abff9f1ea9 100644 --- a/libavcodec/dv.h +++ b/libavcodec/dv.h @@ -63,6 +63,9 @@ enum DVPackType { // LCM of video framerate numerators #define DV_TIMESCALE_VIDEO 60000 +// LCM of audio sample rates +#define DV_TIMESCALE_AUDIO 14112000 + /** * maximum number of blocks per macroblock in any DV format */ |