Граф коммитов

85 Коммитов

Автор SHA1 Сообщение Дата
Bryce Van Dyk d693392c8d Bug 1522547 - Have MediaKeys observe if the owning document becomes inactive so it can shutdown. r=cpearce
MediaKeys objects are typically created and associated with an HTMLMediaElement,
however it is possible to create a MediaKeys object and not associate it with an
HTMLMediaElement.

This resulted in an issue where these MediaKeys would keep alive other
components that would assert during bowrser shutdown (see bug 1522547). We
anticipated that MediaKeys associated with an HTMLMediaElement would need to be
shutdown if their owning document became inactive, but were not handling the
case where the keys never became associated with an element.

This patch has the MediaKeys listen directly to their owning document for
activity change. The MediaKeys will shutdown if their document becomes inactive.
This avoids MediaKeys not associated with HTMLMediaElements keeping other
objects alive during browser shutdown.

Differential Revision: https://phabricator.services.mozilla.com/D21983

--HG--
extra : moz-landing-system : lando
2019-03-05 16:21:40 +00:00
Bryce Van Dyk d6a4f8ea86 Bug 1522547 - Add more logs to MediaKeys, use PRIu32 for printing where appropriate. r=cpearce
- Add more logging to MediaKeys.
- Replace the instances of the %d formatter with PRIu32 when printing the
  PromiseId type (which has the underlying uint32_t type).

Differential Revision: https://phabricator.services.mozilla.com/D21981

--HG--
extra : moz-landing-system : lando
2019-03-05 16:21:28 +00:00
arthur.iakab e91653a3fb Backed out changeset d37ccbbcd36d (bug 1522951) for Android build bustages on MediaDrmCDMProxy.h CLOSED TREE 2019-01-31 22:42:35 +02:00
Andrew McCreight 4ec91b01d2 Bug 1522951 - Get rid of ChromiumCDMProxy::mCrashHelper. r=jya
This field is only used to pass a pointer from the ctor to the Init()
method. Instead, just pass in the crash helper directly.

This avoids some problems with the existing code where the crash
helper is not AddRefed immediately after creation, which could lead to
leaks in some error cases.

Differential Revision: https://phabricator.services.mozilla.com/D17707

--HG--
extra : moz-landing-system : lando
2019-01-31 20:14:31 +00:00
Ehsan Akhgari e5e885ae31 Bug 1521000 - Part 2: Adjust our clang-format rules to include spaces after the hash for nested preprocessor directives r=sylvestre
# ignore-this-changeset

--HG--
extra : amend_source : 7221c8d15a765df71171099468e7c7faa648f37c
extra : histedit_source : a0cce6015636202bff09e35a13f72e03257a7695
2019-01-18 10:16:18 +01:00
John Lin 9249bf1d0a Bug 1495053 - p3: implement MediaDrmCDMProxy::SetServerCertificate(). r=cpearce
Differential Revision: https://phabricator.services.mozilla.com/D7792

--HG--
extra : moz-landing-system : lando
2018-12-07 14:44:34 +00:00
Sylvestre Ledru 804b8b8883 Bug 1204606 - Reformat of dom/media r=jya
# skip-blame

Differential Revision: https://phabricator.services.mozilla.com/D12251

--HG--
extra : moz-landing-system : lando
2018-11-19 13:25:37 +00:00
Jeff Gilbert 5b753da289 Bug 1470325 - s/FooBinding/Foo_Binding/g - r=qdot
MozReview-Commit-ID: JtTcLL5OPF0
2018-06-26 17:05:01 -07:00
Gerald Squelart 1b357db99b Bug 1407810 - Use DDLogger in media stack - r=jwwang
Mostly-mechanical additions:
- Log constructions&destructions, usually by just inheriting from
  DecoderDoctorLifeLogger, otherwise with explicit log commands (for internal
  classes for which DecoderDoctorTraits can't be specialized),
- Log links between most objects, e.g.: Media element -> decoder -> state
  machine -> reader -> demuxer -> resource, etc.

And logging some important properties and events (JS events, duration change,
frames being decoded, etc.)

More will be added later on, from just converting MOZ_LOGs, and as needed.

MozReview-Commit-ID: KgNhHSz35t0

--HG--
extra : rebase_source : dd7206e350e32671adc6f3b9e54ebf777251de2c
2017-10-10 17:55:27 +11:00
James Cheng f733aff224 Bug 1404230 - Part4 - Add GetStatusForPolicy method in ipdl and implement it by calling CDM. r=cpearce
MozReview-Commit-ID: 8L0qKgnKMES

--HG--
extra : rebase_source : 05b6fe33a9c0cbe5ca52f245decc167889bbe6d9
2017-10-24 10:55:03 +08:00
James Cheng 0df3d7fa98 Bug 1404230 - Part2 - Add a web api to support HDCP policy check on MediaKeys. r=cpearce,smaug
MozReview-Commit-ID: HW7DtQ6GuOa

--HG--
extra : rebase_source : 27c4fe3845068d979cac1868d0a7cf9262a3e153
2017-10-02 17:39:00 +08:00
James Cheng 9fcb294cc3 Bug 1398628 - Remove VIDEO_CDM_CREATED telemetry and the related code. r=cpearce,francois
MozReview-Commit-ID: 3xDiz9S90bY

--HG--
extra : rebase_source : 78c88ef859fbf402cb7f1c168663c63f3eb5073d
2017-09-11 11:51:12 +08:00
James Cheng b01615f4a0 Bug 1395468 - [Part2] Remove the EMEVideoDecoder and GMPCDMProxy related files. r=cpearce
We remove the instantiation of EMEVideoDecoder and GMPCDMProxy in Part1. Just delete it and its h/cpp from moz.build

MozReview-Commit-ID: 8kGQK967pR0

--HG--
extra : rebase_source : 77750e6a92e6b649c41e7a8f769fa14c810e8e18
2017-08-29 16:52:09 +08:00
James Cheng 9d0d797c01 Bug 1395468 - [Part1] Remove media.eme.chromium-api.enabled preference and its related code. r=cpearce
1. Delete MediaPrefs::EMEChromiumAPIEnabled() and related logic.
2. We now only use the Chromium CDM interface so delete the opposite side check of MediaPrefs::EMEChromiumAPIEnabled().

MozReview-Commit-ID: GDFrrf4WlWf

--HG--
extra : rebase_source : 987667dd47757afd58e7da10b60c0e1e1ec89d39
2017-08-29 16:13:15 +08:00
Chris Pearce 344a04e025 Bug 1390748 - Remove some unnecessary includes. r=jwwang
MozReview-Commit-ID: J3viRI4Q6LF

--HG--
extra : rebase_source : b2e3f66a20f431b8a2b0dc88b65dd5da9433da2f
2017-08-16 17:18:39 +12:00
Carsten "Tomcat" Book a16900ac51 Backed out changeset 9172b8d6ce3e (bug 1390748)
--HG--
extra : rebase_source : 44c2361c7247fe7d1948ff3e7f47f165e8368483
2017-08-17 08:35:23 +02:00
Chris Pearce bd4996facd Bug 1390748 - Remove some unnecessary includes. r=jwwang
MozReview-Commit-ID: J3viRI4Q6LF

--HG--
extra : rebase_source : 0f2ff9241c643d49c8293bdbfb4ec6adb1e2cd30
2017-08-16 17:18:39 +12:00
Phil Ringnalda 38ce1ea2a0 Backed out 10 changesets (bug 1390748) for build bustage
Backed out changeset 02b36ee5fb17 (bug 1390748)
Backed out changeset 84e8bf01c856 (bug 1390748)
Backed out changeset fc8989be30f3 (bug 1390748)
Backed out changeset 14d421ace6cc (bug 1390748)
Backed out changeset 7dadac869038 (bug 1390748)
Backed out changeset 0e77809e7bc2 (bug 1390748)
Backed out changeset bf78a8dce9c5 (bug 1390748)
Backed out changeset 5fa77990472e (bug 1390748)
Backed out changeset 5d3b637d2485 (bug 1390748)
Backed out changeset 634fe076d134 (bug 1390748)

MozReview-Commit-ID: Dxio8vXDCHg
2017-08-16 21:33:10 -07:00
Chris Pearce e927f10587 Bug 1390748 - Remove some unnecessary includes. r=jwwang
MozReview-Commit-ID: J3viRI4Q6LF

--HG--
extra : rebase_source : 6661db3a00fc8b378aedd456950fb819f699507b
2017-08-16 17:18:39 +12:00
Chris Pearce 1c7befff21 Bug 1388288 - Make EME/GMP related code build non-Unified. r=gerald
MozReview-Commit-ID: 5q0Wwr2BNA0

--HG--
extra : rebase_source : e32e90c06ac933b3a387e26dbbfdcfac93ef3faf
2017-08-08 16:36:01 +08:00
Chris Pearce a619213252 Bug 1315850 - Create ChromiumCDMProxy in MediaKeys.cpp when preffed on. r=gerald
MozReview-Commit-ID: G37QlP74esb

--HG--
extra : rebase_source : 76937006b9e424f2588e7d06f8f7b0c3a68b5af2
2017-02-22 14:42:55 +13:00
JW Wang 3be61ebd8d Bug 1345753 - Pass the event target to the CDMProxy constructor. r=cpearce
MozReview-Commit-ID: 94QzJ5FnGDo

--HG--
extra : rebase_source : b863f95c7906327f00eb8e08dd5b7f37a3b3cc6c
extra : source : 6e6242c50af23128b23d3b955a081481cec0b6e2
2017-03-09 14:58:18 +08:00
Chris Pearce 825ed9ed70 Bug 1345680 - Use ToString(MediaKeySessionType) in EME code. r=jwwang
MozReview-Commit-ID: 5MK7j7THKgW

--HG--
extra : rebase_source : c9e456d7b30475e6a204f2f9b0f6762a0e74890b
2017-03-09 12:35:33 +13:00
karo 85319b4cd0 Bug 1344073 - Adding consistent formatting to HTMLMediaElement::MozRequestDebugInfo debugInfo dump string. r=cpearce
MozReview-Commit-ID: GfRrLQcebbt

--HG--
extra : rebase_source : 846b74c63528f58e414636654b0167d6c8c1480b
2017-03-01 16:03:01 +13:00
JW Wang 2df35d6eb8 Bug 1345324 - Label runnables for CDMProxy sub-classes. r=cpearce
MozReview-Commit-ID: Fpf29Kctmxs

--HG--
extra : rebase_source : 24612112d4b474812e5fdcd2e14cd3679715c098
extra : source : f5d085c3221ec54785f9c98a5fd0eda78d446641
2017-03-07 15:32:10 +08:00
Daniel Holbert 95a650ec1b Bug 1343975: Get rid of all dos/windows linebreaks in Mozilla C++ code. r=ehsan
This is an automated patch, generated by the following command:
find . -name "*.h" -exec fromdos {} \; && \
  find . -name "*.cpp" -exec fromdos {} \; && \
  hg revert -C gfx/angle \
               gfx/sfntly \
               media/webrtc \
               media/libstagefright \
               media/openmax_il \
               other-licenses

MozReview-Commit-ID: Gunlz3vE3h6
2017-03-02 13:08:29 -08:00
karo 3c2b014e09 Bug 1343409 - HTMLMediaElement::MozRequestDebugInfo returns EMEInfo. r=cpearce
MozReview-Commit-ID: 1iQP3OJmwdP

--HG--
extra : rebase_source : 171155ab5e58cac8cc9db9109a5c2fc88b1930d3
2017-03-01 12:56:29 +13:00
Tom Tromey 5f8f360823 Bug 1060419 - make log_print use Printf.h, r=froydnj
MozReview-Commit-ID: BIZ1GQEZ1vs

--HG--
extra : rebase_source : 2f1f0aa12493c44f352d9a7e8683e7bb72d2d75b
2016-12-15 20:16:31 -07:00
Andrea Marchesini f7f5990527 Bug 1317927 - Media caching needs to use origin attributes, r=cpearce, r=jesup 2016-12-07 07:07:09 -10:00
Chris Pearce 19f0b2fe44 Bug 1320614 - Remove MediaKeys::mNodeId as it's only ever written and never read. r=gerald
MozReview-Commit-ID: BWfrjzdfph

--HG--
extra : amend_source : 784b9d8341dc2fad29c522b5faa147a2a81a9388
2016-11-28 12:12:34 +13:00
Chris Pearce 0a0e9d8f06 Bug 1317822 - Move GMPCrashHelper into its own file. r=gerald
MozReview-Commit-ID: 7CinZ2Y2Fmz

--HG--
extra : rebase_source : 3b176cbfadebf6463384105c261ff208bc58b1c2
2016-11-16 11:35:36 +13:00
James Cheng 06a62c3bad Bug 1314530 Part3 - Instantiate MediaDrmCDMProxy if it is widevine on fennec. r=cpearce
MozReview-Commit-ID: AhNBaO5LPwe

--HG--
extra : rebase_source : bd481396058d28521b2cbbd0fca8296d32768a86
2016-11-07 14:03:44 +08:00
Chris Pearce 20b6c3ec6b Bug 1314445 - Don't pass CDM version to MediaKey*. r=gerald
We don't need this, and we don't seem to be using this anyway.

MozReview-Commit-ID: 7NCRO94PN3m

--HG--
extra : rebase_source : de91b099e5e536eb321584990f18025e08c7cc78
2016-11-02 11:56:30 +13:00
Chris Pearce 08bdd39606 Bug 1310879 - Check that only supported session types are instantiated. r=gerald
MozReview-Commit-ID: 6XkToIXzZL8

--HG--
extra : source : d1c0a7a2ff25005de82033081bee5eb10adea0c8
2016-10-28 11:43:26 +13:00
Chris Pearce 17c7c9d886 Bug 1310879 - Pass MediaKeySystemConfiguration to MediaKeys. r=gerald
MozReview-Commit-ID: 6tHlyRl4nWT

--HG--
extra : source : 5773f8dac74aaf05ec1c4f8585b3b148d51da324
2016-10-28 11:22:11 +13:00
Chris Pearce ea73ebebc8 Bug 1311848 - Don't call ConnectPendingPromiseIdWithToken in MediaKeySession::Load. r=kikuo
We don't need to call MediaKeys::ConnectPendingPromiseIdWithToken() on the
MediaKeySession::Load() path, we already know the session Id, and we've already
removed the session from the list of pending sessions in Load().

MozReview-Commit-ID: KBiEsY95Csi

--HG--
extra : rebase_source : aadc3204409df35e4bbcb9532c530f860681afd1
2016-10-21 10:52:26 +13:00
Kilik Kuo ede59e2ecf Bug 1310936- Provide a map to get pending MediaKeySession by promise Id correctly. r=cpearce
MozReview-Commit-ID: 34BL4GYoC1A

--HG--
extra : rebase_source : 4dffdf8da32412a6812716de9edbf685235ce442
2016-10-20 15:28:09 +08:00
Chris Pearce f40bbc42f7 Bug 1305552 - Add telemetry to track uses of MediaKeySession.generateRequest. r=francois,gerald
This allows us to track how often EME CDMs are used, rather than just created.
The telemetry I added in bug 1304207 is reports whenever a CDM is created, but
some sites, such as the Shaka Player demo site, create CDMs without using them,
so that telemetry isn't a great measure in helping us detect when CDMs aren't
being used. Whereas the telemetry added here will report when the CDMs are used
to negotiate a license, i.e. when the CDMs are actually being used.


MozReview-Commit-ID: ExMIcIIBvS1
2016-09-27 15:01:06 +13:00
Chris Pearce 3d1e5d28dd Bug 1304207 - Add telemetry to track when EME CDMs are instantiated. r=francois,gerald
Add opt-out telemetry probe to track which EME CDMs are being instantiated.
This will enable us to determine when it's safe to remove the Adobe CDM.


MozReview-Commit-ID: iEPSTk7UtP

--HG--
extra : rebase_source : fb51d77f4c15fe2d9ef0adf3c87f6125bb758b9c
2016-09-21 10:45:02 +12:00
Jean-Yves Avenard 6a25692b20 Bug 1299072: P10. Pass decoding error details to media element's error attribute. r=jwwang
MozReview-Commit-ID: 49DurV9WI5S

--HG--
extra : rebase_source : 469e6ed4e222fb6d6ac34843c3c3346a044c6023
2016-09-11 00:56:09 +10:00
Kaku Kuo a6ed727230 Bug 1292091 - Part 2 - replace MaybeResolve(JS::UndefinedHandleValue) with MaybeResolveWithUndefined(); r=bz
MozReview-Commit-ID: KNbxVcCVqts

--HG--
extra : transplant_source : %1D%18%E5%C9o%F0%29%E7%E0%93%EEcR%C7B%3BeX%B3%87
2016-08-09 17:15:13 +08:00
Tim Huang 71ca0b6bc8 Bug 1283325 - Part 1 : Make EME Plugins / Gecko Media Plugins storage OriginAttribute aware. r=cpearce 2016-07-22 08:40:00 +02:00
Chris Pearce f49856bc79 Bug 1278198 - Pipe through distinctive identifier and persistent state allowed. r=gerald
MozReview-Commit-ID: A92e0XGp5s4

--HG--
extra : rebase_source : 09f7ba18c9b81263aa345cc7f34f0ef2a2548482
2016-07-07 17:26:15 +12:00
Chris Pearce 1ea9b742f5 Bug 1278198 - Update EME code to reflect new WebIDL name changes. r=gerald
MozReview-Commit-ID: EssCsJxBBwt

--HG--
extra : rebase_source : 154746eca911e2250f3fa94a6a2d4b2624910e50
2016-07-04 14:14:01 +12:00
James Cheng 02c5726f49 Bug 1284192 - Make CDMProxy be a base class and move the logic into subclass. r=cpearce
MozReview-Commit-ID: 4Lr3uqVexFD

--HG--
rename : dom/media/eme/CDMProxy.cpp => dom/media/gmp/GMPCDMProxy.cpp
rename : dom/media/eme/CDMProxy.h => dom/media/gmp/GMPCDMProxy.h
2016-07-18 22:13:00 +02:00
Chris Pearce 4b3a0f0d42 Bug 1267918 - Remove obsolete GMP crash handling code. r=gerald
MozReview-Commit-ID: EqzJagCHk7n

--HG--
extra : rebase_source : e66aa2a4b5939ae8bcf833a5d1a59ef508a679b3
2016-06-29 11:42:14 +12:00
Chris Pearce 7517d84f1b Bug 1267918 - Add GMPCrashHelper for MediaKeys. r=gerald
So if a GMP crashes while doing EME, we'll get a crash report using the new
mechanism.

MozReview-Commit-ID: G8BlFI9jmiF

--HG--
extra : rebase_source : 1cda5c93ea9e547636b34ec2149ef9cd2506ca73
2016-06-29 11:42:04 +12:00
Jean-Yves Avenard d31cb0499b Bug 1206637: P2. Replace all cached preferences with MediaPrefs ones. r=cpearce
Additionally, clean up stray and unused Preferences.h header.

MozReview-Commit-ID: IcPrD2inkDE

--HG--
extra : rebase_source : c3c6e37767627db3601090c2855a3dfa98cb4368
2016-05-10 11:02:28 +10:00
Kyle Huey 91efc5a86c Bug 1241764: Replace nsPIDOMWindow with nsPIDOMWindowInner/Outer. r=mrbkap,smaug 2016-01-30 09:05:36 -08:00
Chris Pearce 967b559ecc Bug 1233274 - Don't shutdown detached MediaKeys. r=gerald 2016-01-06 13:28:43 +13:00