Closed Bug 1220558 Opened 9 years ago Closed 9 years ago

Remove aLength and aOffset from arguments of MediaDecoderReader::DispatchNotifyDataArrived()

Categories

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

defect

Tracking

()

RESOLVED FIXED
mozilla45
Tracking Status
firefox45 --- fixed

People

(Reporter: jwwang, Assigned: jwwang)

References

Details

Attachments

(2 files)

Since bug 1218157 is landded, the arguments are unused anymore.
Assignee: nobody → jwwang
Blocks: 1219142
Depends on: 1220551
Bug 1220558. Part 1 - remove unused arguments from MediaDecoderReader::DispatchNotifyDataArrived() and its callees/callers. r=jya.
Attachment #8682301 - Flags: review?(jyavenard)
Bug 1220558. Part 2 - remove unused members. r=jya.
Attachment #8682302 - Flags: review?(jyavenard)
Priority: -- → P2
Attachment #8682301 - Flags: review?(jyavenard) → review+
Comment on attachment 8682301 [details]
MozReview Request: Bug 1220558. Part 1 - remove unused arguments from MediaDecoderReader::DispatchNotifyDataArrived() and its callees/callers. r=jya.

https://reviewboard.mozilla.org/r/24053/#review21737

Can be even more aggressive in the cleanup. And remove everything related to throttling.
I would much prefer for the MEdiaResource not to fire NotifyDataArrived as often as it does (every 32 kB)

::: dom/media/AbstractMediaDecoder.h:114
(Diff revision 1)
> -  virtual void NotifyDataArrived(uint32_t aLength, int64_t aOffset,
> +  virtual void NotifyDataArrived(bool aThrottleUpdates) = 0;

I would even remove ThrottleUpdates and all the machineray around throttling.

The various NotifyDataArrivedInternal implementation now only ever parse new data ; so throttling is unecessary

::: dom/media/MediaDecoderReader.h:236
(Diff revision 1)
>        aThrottleUpdates ? &MediaDecoderReader::ThrottledNotifyDataArrived :

so this can go and only dispatch MediaDecoderReader::NotifyDataArrived

::: dom/media/MediaDecoderReader.cpp:186
(Diff revision 1)
> -MediaDecoderReader::ThrottledNotifyDataArrived(const Interval<int64_t>& aInterval)
> +MediaDecoderReader::ThrottledNotifyDataArrived()

remove
Comment on attachment 8682302 [details]
MozReview Request: Bug 1220558. Part 2 - remove unused members. r=jya.

https://reviewboard.mozilla.org/r/24055/#review21739

::: dom/media/MediaDecoderReader.h:366
(Diff revision 1)
>    MozPromiseRequestHolder<MediaTimerPromise> mThrottledNotify;

Assuming all of this will also go in the previous patch
Attachment #8682302 - Flags: review?(jyavenard) → review+
(In reply to Jean-Yves Avenard [:jya] from comment #5)
> Can be even more aggressive in the cleanup. And remove everything related to
> throttling.
> I would much prefer for the MEdiaResource not to fire NotifyDataArrived as
> often as it does (every 32 kB)

I will do that in a new bug because the rationale for removing throttling isn't as trivia as removing first 2 arguments in this bug.
Blocks: 1223599
https://hg.mozilla.org/mozilla-central/rev/ef5ac56a15d2
https://hg.mozilla.org/mozilla-central/rev/b509735f38af
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla45
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: