Closed
Bug 1048107
Opened 11 years ago
Closed 11 years ago
[EME] Implement GMPTimer and clock
Categories
(Core :: Audio/Video, defect)
Tracking
()
RESOLVED
FIXED
mozilla34
People
(Reporter: cpearce, Assigned: cpearce)
References
Details
Attachments
(1 file)
21.67 KB,
patch
|
jesup
:
review+
|
Details | Diff | Splinter Review |
Implement GMPTimer interfaces, and the GMPGetCurrentTime function that lives in GMPPlatformAPI.
Assignee | ||
Comment 1•11 years ago
|
||
Implements GMPTimer. Service is requested and instantiated on the child process side first, unlike our other interfaces.
Also adds a placeholder implementation of GMPGetCurrentTime.
Attachment #8466877 -
Flags: review?(rjesup)
Comment 2•11 years ago
|
||
Comment on attachment 8466877 [details] [diff] [review]
Patch v1
Review of attachment 8466877 [details] [diff] [review]:
-----------------------------------------------------------------
::: content/media/gmp/GMPChild.h
@@ +62,5 @@
>
> virtual void ActorDestroy(ActorDestroyReason aWhy) MOZ_OVERRIDE;
> virtual void ProcessingError(Result aWhat) MOZ_OVERRIDE;
>
> + nsRefPtr<GMPTimerChild> mTimerChild;
spaces
::: content/media/gmp/GMPTimerChild.cpp
@@ +41,5 @@
> + return GMPQuotaExceededErr;
> + }
> + uint32_t timerId = mTimerCount;
> + mTimers.Put(timerId, aTask);
> + mTimerCount++;
thread assertion, since we're not locking? However, maybe irrelevant since we call SendSetTimer(), and I think the IPC code asserts on threads.
Attachment #8466877 -
Flags: review?(rjesup) → review+
Assignee | ||
Comment 3•11 years ago
|
||
(In reply to Randell Jesup [:jesup] from comment #2)
> ::: content/media/gmp/GMPTimerChild.cpp
> @@ +41,5 @@
> > + return GMPQuotaExceededErr;
> > + }
> > + uint32_t timerId = mTimerCount;
> > + mTimers.Put(timerId, aTask);
> > + mTimerCount++;
>
> thread assertion, since we're not locking? However, maybe irrelevant since
> we call SendSetTimer(), and I think the IPC code asserts on threads.
We return failure on line 35 if this is called on a non-main thread. We could assert as well, so that the issue is more visible to plugin authors?
Assignee | ||
Comment 4•11 years ago
|
||
Backed out in https://hg.mozilla.org/integration/mozilla-inbound/rev/7b2c2cc747db for build bustage: https://tbpl.mozilla.org/php/getParsedLog.php?id=45200545&tree=Mozilla-Inbound
Flags: needinfo?(cpearce)
Assignee | ||
Updated•11 years ago
|
Flags: needinfo?(cpearce)
Assignee | ||
Comment 6•11 years ago
|
||
Comment on attachment 8466877 [details] [diff] [review]
Patch v1
Review of attachment 8466877 [details] [diff] [review]:
-----------------------------------------------------------------
::: content/media/gmp/GMPParent.cpp
@@ +627,5 @@
> +
> +PGMPTimerParent*
> +GMPParent::AllocPGMPTimerParent()
> +{
> + GMPTimerParent* p = new GMPTimerParent(GMPThread());
Bustage fix: GMPThread() is only defined in debug builds. It needs to be present in opt builds too, and I think we're better off naming it GetGMPThread(), so that it doesn't conflict with the name of the threads that we expose to the GMPs; GMPThread.
::: content/media/gmp/GMPTimerParent.cpp
@@ +64,5 @@
> +void
> +GMPTimerParent::GMPTimerExpired(nsITimer *aTimer, void *aClosure)
> +{
> + MOZ_ASSERT(aClosure);
> + nsAutoPtr<Context> ctx = static_cast<Context*>(aClosure);
Bustage fix:
nsAutoPtr<Context> ctx(static_cast<Context*>(aClosure));
Assignee | ||
Comment 7•11 years ago
|
||
Assignee | ||
Comment 8•11 years ago
|
||
Somehow I managed to not include my bustage fix in my push when I pushed to inbound...
Fix: https://hg.mozilla.org/integration/mozilla-inbound/rev/7cb757252c04
Comment 9•11 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/238e2c78035c
https://hg.mozilla.org/mozilla-central/rev/7cb757252c04
Status: NEW → 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.
Description
•