Bug 750258. Set intial audio capture state correctly on mDecoderStateMachine. r=cpearce

For media resources whose streams are captured before the load has started, we shouldn't even start
an audio thread. This saves a lot of resources and ensures we don't see races between the audio thread
and the code that copies packets from the audio queue to the MediaStreams.
This commit is contained in:
Robert O'Callahan 2012-05-07 15:45:06 +12:00
parent b1c494a351
commit 094c73799f

View File

@ -246,6 +246,7 @@ nsresult nsBuiltinDecoder::Load(MediaResource* aResource,
mDecoderStateMachine->SetSeekable(mSeekable);
mDecoderStateMachine->SetDuration(mDuration);
mDecoderStateMachine->SetVolume(mInitialVolume);
mDecoderStateMachine->SetAudioCaptured(mInitialAudioCaptured);
if (mFrameBufferLength > 0) {
// The valid mFrameBufferLength value was specified earlier