Bug 941283 - OpusTrackEncoder should write pre-skip at the original samplerate. r=rillian

This commit is contained in:
Shelly Lin 2013-12-02 11:54:35 +08:00
parent fe84e8aadd
commit 8873339903

View File

@ -212,8 +212,9 @@ OpusTrackEncoder::GetMetadata()
}
// The ogg time stamping and pre-skip is always timed at 48000.
SerializeOpusIdHeader(mChannels, mLookahead*(kOpusSamplingRate/mSamplingRate),
mSamplingRate, &meta->mIdHeader);
SerializeOpusIdHeader(mChannels, mLookahead * (kOpusSamplingRate /
GetOutputSampleRate()), mSamplingRate,
&meta->mIdHeader);
nsCString vendor;
vendor.AppendASCII(opus_get_version_string());