Closed Bug 1294656 Opened 8 years ago Closed 8 years ago

Seek to nearest keyframe when resuming videos with no audio - no audio track

Categories

(Core :: Audio/Video: Playback, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla51
Tracking Status
firefox51 --- fixed

People

(Reporter: kaku, Assigned: kaku)

References

(Blocks 2 open bugs)

Details

Attachments

(1 file)

A sub-bug of Bug 1282012.

While resuming from background, apply FastSeek to video files without audio track.
Assignee: nobody → kaku
Blocks: 1282012
Comment on attachment 8780459 [details]
Bug 1294656 - apply FastSeek to video files without audio track;

https://reviewboard.mozilla.org/r/71164/#review68676

::: dom/media/MediaDecoderStateMachine.cpp:1373
(Diff revision 1)
>      }
>  
>      // Start video-only seek to the current time...
>      SeekJob seekJob;
> +
> +    if (!HasAudio()) {

You can do:

SeekTarget::Type type = HasAudio() ? SeekTarget::Type::Accurate : SeekTarget::Type::PrevSyncPoint;

seekJob.mTarget = SeekTarget(..., type, ...);

so you have less redundant code.
Attachment #8780459 - Flags: review?(jwwang) → review+
Try: https://treeherder.mozilla.org/#/jobs?repo=try&revision=7f0cb0e5aa49
The problems in Android platform seems not related to this bug.

Thanks for the review!
Keywords: checkin-needed
Pushed by ryanvm@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/a5dc69346897
apply FastSeek to video files without audio track; r=jwwang
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/a5dc69346897
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla51
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: