Closed
Bug 1163445
Opened 8 years ago
Closed 8 years ago
Replace usage of dom::TimeRanges with TimeIntervals object
Categories
(Core :: Audio/Video, defect)
Core
Audio/Video
Tracking
()
RESOLVED
FIXED
mozilla41
People
(Reporter: jya, Assigned: jya)
References
(Blocks 1 open bug)
Details
Attachments
(5 files, 6 obsolete files)
19.50 KB,
patch
|
mattwoodrow
:
review+
|
Details | Diff | Splinter Review |
7.11 KB,
patch
|
mattwoodrow
:
review+
|
Details | Diff | Splinter Review |
1.59 KB,
patch
|
mattwoodrow
:
review+
|
Details | Diff | Splinter Review |
108.55 KB,
patch
|
mattwoodrow
:
review+
|
Details | Diff | Splinter Review |
4.27 KB,
patch
|
Details | Diff | Splinter Review |
This will be required for using the state-mirroring machinery introduced in bug 1144481
Assignee | ||
Comment 1•8 years ago
|
||
Keep IntervalSet normalized. Update unit tests. Keeping it normalized in 99% of our usage will add no overhead.
Attachment #8606068 -
Flags: review?(matt.woodrow)
Assignee | ||
Updated•8 years ago
|
Assignee: nobody → jyavenard
Status: NEW → ASSIGNED
Assignee | ||
Comment 2•8 years ago
|
||
Add an TimeUnit::Infinite() object. As TimeRanges use doubles, it can store infinity, and this is a required time interval for media with inifnite duration (such as a stream). In order to save storing an extra bool, we use INT64_MAX as meaning infinity (similar as what the MediaDecoderStateMachine use).
Attachment #8606069 -
Flags: review?(matt.woodrow)
Assignee | ||
Comment 3•8 years ago
|
||
Keep IntervalSet normalized. Update unit tests. Keeping it normalized in 99% of our usage will add no overhead.
Attachment #8606070 -
Flags: review?(matt.woodrow)
Assignee | ||
Updated•8 years ago
|
Attachment #8606068 -
Attachment is obsolete: true
Attachment #8606068 -
Flags: review?(matt.woodrow)
Assignee | ||
Comment 4•8 years ago
|
||
Add an TimeUnit::Infinite() object. As TimeRanges use doubles, it can store infinity, and this is a required time interval for media with inifnite duration (such as a stream). In order to save storing an extra bool, we use INT64_MAX as meaning infinity (similar as what the MediaDecoderStateMachine use).
Attachment #8606071 -
Flags: review?(matt.woodrow)
Assignee | ||
Updated•8 years ago
|
Attachment #8606069 -
Attachment is obsolete: true
Attachment #8606069 -
Flags: review?(matt.woodrow)
Assignee | ||
Comment 5•8 years ago
|
||
Add IntervalSet::Contains(Interval) method. Missed that one
Attachment #8606072 -
Flags: review?(matt.woodrow)
Assignee | ||
Updated•8 years ago
|
Attachment #8606072 -
Attachment is obsolete: true
Attachment #8606072 -
Flags: review?(matt.woodrow)
Assignee | ||
Comment 7•8 years ago
|
||
Add IntervalSet::SetFuzz method; we'll make use of it with MediaSource
Attachment #8606074 -
Flags: review?(matt.woodrow)
Assignee | ||
Comment 8•8 years ago
|
||
Add IntervalSet::SetFuzz method; we'll make use of it with MediaSource. Fix constness I just noticed
Attachment #8606078 -
Flags: review?(matt.woodrow)
Assignee | ||
Updated•8 years ago
|
Attachment #8606074 -
Attachment is obsolete: true
Attachment #8606074 -
Flags: review?(matt.woodrow)
Assignee | ||
Comment 9•8 years ago
|
||
Replace TimeRanges with TimeIntervals in all media code. TimeRanges is now only used to return objects to the JS
Attachment #8606124 -
Flags: review?(matt.woodrow)
Assignee | ||
Comment 10•8 years ago
|
||
The test now almost always succeed. However, I do get the occasional timeout every once in a while. May have to completely disable this test.
Attachment #8606724 -
Flags: review?(karlt)
Updated•8 years ago
|
Attachment #8606724 -
Flags: review?(karlt) → review+
Assignee | ||
Comment 11•8 years ago
|
||
Comment on attachment 8606724 [details] [diff] [review] Part6. Update webref test Actually, that one is for bug 1163485.
Assignee | ||
Updated•8 years ago
|
Attachment #8606724 -
Attachment is obsolete: true
Updated•8 years ago
|
Attachment #8606070 -
Flags: review?(matt.woodrow) → review+
Updated•8 years ago
|
Attachment #8606071 -
Flags: review?(matt.woodrow) → review+
Comment 12•8 years ago
|
||
Comment on attachment 8606071 [details] [diff] [review] Part2. Add TimeUnit infinity concept Review of attachment 8606071 [details] [diff] [review]: ----------------------------------------------------------------- ::: dom/media/TimeUnits.h @@ +133,4 @@ > return TimeUnit(mValue + aOther.mValue); > } > TimeUnit operator - (const TimeUnit& aOther) const { > + if (IsInfinite() && !aOther.IsInfinite()) { What if !IsInfinite() && aOther.IsInfinite()? I'm not even sure what the right behaviour is there.
Updated•8 years ago
|
Attachment #8606073 -
Flags: review?(matt.woodrow) → review+
Updated•8 years ago
|
Attachment #8606078 -
Flags: review?(matt.woodrow) → review+
Updated•8 years ago
|
Attachment #8606124 -
Flags: review?(matt.woodrow) → review+
Assignee | ||
Comment 13•8 years ago
|
||
(In reply to Matt Woodrow (:mattwoodrow) from comment #12) > Comment on attachment 8606071 [details] [diff] [review] > Part2. Add TimeUnit infinity concept > > Review of attachment 8606071 [details] [diff] [review]: > ----------------------------------------------------------------- > > ::: dom/media/TimeUnits.h > @@ +133,4 @@ > > return TimeUnit(mValue + aOther.mValue); > > } > > TimeUnit operator - (const TimeUnit& aOther) const { > > + if (IsInfinite() && !aOther.IsInfinite()) { > > What if !IsInfinite() && aOther.IsInfinite()? I'm not even sure what the > right behaviour is there. nonInfinite - infinite = - infinite. I think we should just assert. I had thought of keeping a float alongside the int64_t mValue ; just so it would take care of all the oo / NaN etc... may be easier that way, though we would increase the size of TimeUnit by 4 bytes. which is why i didn't use a bool in the first place to indicate oo.
Assignee | ||
Comment 14•8 years ago
|
||
Carrying r+, assert should attempting to permorm infinity calculations. It should never be used in the current code. https://treeherder.mozilla.org/#/jobs?repo=try&revision=985297f63a88
Assignee | ||
Updated•8 years ago
|
Attachment #8606071 -
Attachment is obsolete: true
Comment 15•8 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/4c86cc335c31 https://hg.mozilla.org/integration/mozilla-inbound/rev/d71d9f13a37d https://hg.mozilla.org/integration/mozilla-inbound/rev/7cc62c82bb10 https://hg.mozilla.org/integration/mozilla-inbound/rev/0fe9422de17b https://hg.mozilla.org/integration/mozilla-inbound/rev/24a7f0fda98b
Comment 16•8 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/4c86cc335c31 https://hg.mozilla.org/mozilla-central/rev/d71d9f13a37d https://hg.mozilla.org/mozilla-central/rev/7cc62c82bb10 https://hg.mozilla.org/mozilla-central/rev/0fe9422de17b https://hg.mozilla.org/mozilla-central/rev/24a7f0fda98b
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
status-firefox41:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla41
You need to log in
before you can comment on or make changes to this bug.
Description
•