Hi All,
Following up on the discussion regarding GMPs we had at the meetup of media
developers at mozlando so that we don't forget discussing these...
We discussed improving the robustness of the GMP startup and shutdown code. In
particular I suggested we switch to using nsIAsyncShutdown for GMP plugin and
service shutdown, and that we refactor and simplify the shutdown of GMPParent
instances in general.
I also suggested that we change the way GetContentParent and
GetGMP%Actor%Callback, to instead either use promises or mozilla::Function.
For example:
// mozIGeckoMediaPluginService.idl
typedef mozilla::Function<bool(GMPDecryptorProxy*, GMPVideoHost*))
GetGMPVideoDecoderProxyFunc;
[noscript]
void getGMPVideoDecoder(in TagArray tags,
[optional] in ACString nodeId,
in GetGMPVideoDecoderProxyFunc callback);
Or, even better, return a MozPromise!
using GetGMPVideoDecoderPromise =
MozPromise<RefPtr<GMPVideoDecoderProxy>, nsresult, IsExclusive>;
RefPtr<GetGMPVideoDecoderPromise>
getGMPVideoDecoder(in TagArray tags,
[optional] in ACString nodeId);
We may be able to move the GMPService away from being an XPCOM service too,
having the stuff that needs to be exposed to chrome exposed by a chrome-only
WebIDL interface.
cpearce.
_______________________________________________
dev-media mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-media