зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1409272 - P2. Pre-roll vorbis by 80ms when seeking. r=gerald
The value by which we pre-roll is inconsequential, so long as we seek to the previous packet than the one we want. So 80ms will do. MozReview-Commit-ID: 8iPOtjReZnb --HG-- extra : rebase_source : 42908c6afc84cf783356fb7311ffe99b4ec76d96
This commit is contained in:
Родитель
85eb08473d
Коммит
38b456068a
|
@ -9,6 +9,7 @@
|
|||
#include "MediaSourceUtils.h"
|
||||
#include "OpusDecoder.h"
|
||||
#include "SourceBufferList.h"
|
||||
#include "VorbisDecoder.h"
|
||||
#include "nsPrintfCString.h"
|
||||
|
||||
#include <algorithm>
|
||||
|
@ -307,7 +308,8 @@ MediaSourceTrackDemuxer::MediaSourceTrackDemuxer(MediaSourceDemuxer* aParent,
|
|||
, mManager(aManager)
|
||||
, mReset(true)
|
||||
, mPreRoll(TimeUnit::FromMicroseconds(
|
||||
OpusDataDecoder::IsOpus(mParent->GetTrackInfo(mType)->mMimeType)
|
||||
OpusDataDecoder::IsOpus(mParent->GetTrackInfo(mType)->mMimeType) ||
|
||||
VorbisDataDecoder::IsVorbis(mParent->GetTrackInfo(mType)->mMimeType)
|
||||
? 80000
|
||||
: mParent->GetTrackInfo(mType)->mMimeType.EqualsLiteral("audio/mp4a-latm")
|
||||
// AAC encoder delay is by default 2112 audio frames.
|
||||
|
|
Загрузка…
Ссылка в новой задаче