Closed Bug 1055899 Opened 11 years ago Closed 11 years ago

Handle audio decoder resets from a SourceBuffer by switching to the new audio decoder

Categories

(Core :: Audio/Video, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla34

People

(Reporter: kinetik, Assigned: kinetik)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

Spinning off from bug 1041374. Addressed review comments from that bug and rearranged the code a bit.
Blocks: MSE
Comment on attachment 8475627 [details] [diff] [review] Handle audio decoder resets from a SourceBuffer by switching to the new audio decoder. v2 Review of attachment 8475627 [details] [diff] [review]: ----------------------------------------------------------------- ::: content/media/mediasource/MediaSourceReader.cpp @@ +218,5 @@ > SubBufferDecoder* decoder = mDecoders[i]; > > + const MediaInfo& info = decoder->GetReader()->GetMediaInfo(); > + > + double decodeTarget = double(mTimeThreshold) / USECS_PER_S; We should be able to move this outside the loop I think.
Attachment #8475627 - Flags: review?(cajbir.bugzilla) → review+
Comment on attachment 8475627 [details] [diff] [review] Handle audio decoder resets from a SourceBuffer by switching to the new audio decoder. v2 Review of attachment 8475627 [details] [diff] [review]: ----------------------------------------------------------------- ::: content/media/mediasource/MediaSourceReader.cpp @@ +238,5 @@ > + if (info.HasAudio()) { > + didSwitch = SwitchAudioReader(mDecoders[i]->GetReader()); > + } > + if (info.HasVideo()) { > + didSwitch = SwitchVideoReader(mDecoders[i]->GetReader()); Should these be "didSwitch |=" so we don't lose information if a later decoder doesn't switch?
Yep. I'll change that and comment 2 on commit.
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla34
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: