Skip to content

Commit

Permalink
Merge branch 'main' into chrisn-editorial
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisn authored Jul 17, 2024
2 parents 2b92a89 + 35e5eaa commit e97424c
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 69 deletions.
89 changes: 23 additions & 66 deletions index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ Shortname: media-capabilities
Level: None
Group: mediawg
Editor: Jean-Yves Avenard, w3cid 115886, Apple Inc. https://www.apple.com/
Editor: Will Cassella, w3cid 139598, Google Inc. https://www.google.com/

Former Editor: Will Cassella, w3cid 139598, Google Inc. https://www.google.com/
Former Editor: Mounir Lamouri, w3cid 45389, Google Inc. https://www.google.com/
Former Editor: Chris Cunningham, w3cid 114832, Google Inc. https://www.google.com/
Former Editor: Vi Nguyen, w3cid 116349, Microsoft Corporation https://www.microsoft.com/
Expand All @@ -32,47 +32,13 @@ spec: media-source; urlPrefix: https://www.w3.org/TR/media-source/
type: method
for: MediaSource; text: isTypeSupported(); url: #dom-mediasource-istypesupported

spec: html; urlPrefix: https://html.spec.whatwg.org/multipage/;
type: method
for: HTMLMediaElement; text: canPlayType(); url: #dom-navigator-canplaytype
type: dfn
text: rules for parsing floating-point number values
type: dfn;
text: origin; url:#concept-origin
text: global object; url:#global-object
text: relevant settings object; url:#relevant-settings-object

spec: ECMAScript; urlPrefix: https://tc39.es/ecma262/#
type: interface
text: TypeError; url: sec-native-error-types-used-in-this-standard-typeerror

spec: cssom-view; urlPrefix: https://drafts.csswg.org/cssom-view/#
type: interface
text: Screen; url: screen

spec: mediaqueries-4; urlPrefix: https://drafts.csswg.org/mediaqueries-4/#
type: interface
text: color-gamut

spec: mediastream-recording; urlPrefix: https://www.w3.org/TR/mediastream-recording/#
type:interface
text: MediaRecorder; url: mediarecorder

spec: webrtc-svc; urlPrefix: https://www.w3.org/TR/webrtc-svc/#
type: interface
text: scalabilityMode; url: interface-definition

spec: mimesniff; urlPrefix: https://mimesniff.spec.whatwg.org/#
type: dfn; text: valid mime type; url: valid-mime-type

spec: webidl; urlPrefix: https://heycam.github.io/webidl/#
type: dfn; text: SecurityError; url:securityerror
type: interface; text: DOMException; url:idl-DOMException
type: dfn; text: InvalidStateError; url:invalidstateerror

spec: dom; urlPrefix: https://dom.spec.whatwg.org/#
type: dfn; text: Document; url:concept-document

spec: encrypted-media; for: EME; urlPrefix: https://www.w3.org/TR/encrypted-media/#
type: attribute
text: keySystem; url: dom-mediakeysystemaccess-keysystem
Expand All @@ -98,9 +64,6 @@ spec: encrypted-media; for: EME; urlPrefix: https://www.w3.org/TR/encrypted-medi
spec: encrypted-media-draft; for: EME; urlPrefix: https://w3c.github.io/encrypted-media/#
type: attribute
text: encryptionScheme; url: dom-mediakeysystemmediacapability-encryptionscheme

spec: secure-contexts; urlPrefix: https://www.w3.org/TR/secure-contexts/
type: dfn; text: Is the environment settings object settings a secure context?; url: #settings-object
</pre>

<pre class='biblio'>
Expand Down Expand Up @@ -801,13 +764,17 @@ spec: secure-contexts; urlPrefix: https://www.w3.org/TR/secure-contexts/
booleans.
</p>

<p class='note'>
Authors can use {{MediaCapabilitiesInfo/powerEfficient}} in concordance
with the Battery Status API [[battery-status]] to determine
whether the media they would like to play is appropriate for the user
configuration. It is worth noting that even when a device is not power
constrained, high power usage has side effects such as increasing the
temperature or fan noise.
<p>
Encoding or decoding is considered <dfn>power efficient</dfn> when the
power draw is optimal. The definition of optimal power draw for encoding
or decoding is left to the user agent. However, a common implementation
strategy is to consider hardware usage as indicative of optimal power
draw. User agents SHOULD NOT mark hardware encoding or decoding as power
efficient by default, as non-hardware-accelerated codecs can be just as
efficient, particularly with low-resolution video. User agents SHOULD
NOT take the device's power source into consideration when determining
encoding power efficiency unless the device's power source has side
effects such as enabling different encoding or decoding modules.
</p>

<p>
Expand Down Expand Up @@ -874,13 +841,9 @@ spec: secure-contexts; urlPrefix: https://www.w3.org/TR/secure-contexts/
</li>
<li>
If the user agent is able to encode the media represented by
<var>configuration</var> in a power efficient manner, set
<var>configuration</var> in a [=power efficient=] manner, set
{{MediaCapabilitiesInfo/powerEfficient}} to <code>true</code>.
Otherwise set it to <code>false</code>. The user agent SHOULD NOT
take into consideration the current power source in order to
determine the encoding power efficiency unless the device's power
source has side effects such as enabling different encoding
modules.
Otherwise set it to <code>false</code>.
</li>
<li>
Return <var>info</var>.
Expand Down Expand Up @@ -948,13 +911,9 @@ spec: secure-contexts; urlPrefix: https://www.w3.org/TR/secure-contexts/
</li>
<li>
If the user agent is able to decode the media represented by
<var>configuration</var> in a power efficient
<var>configuration</var> in a [=power efficient=]
manner, set {{MediaCapabilitiesInfo/powerEfficient}} to
<code>true</code>. Otherwise set it to <code>false</code>. The
user agent SHOULD NOT take into consideration the current
power source in order to determine the decoding power
efficiency unless the device's power source has side effects
such as enabling different decoding modules.
<code>true</code>. Otherwise set it to <code>false</code>.
</li>
<li>
Return <var>info</var>.
Expand All @@ -980,8 +939,8 @@ spec: secure-contexts; urlPrefix: https://www.w3.org/TR/secure-contexts/
<code>null</code>. String comparison is case-sensitive.
</li>
<li>
Let <var>origin</var> be the <a>origin</a> of the calling
context's <a>Document</a>.
Let <var>origin</var> be the [=/origin=] of the calling context's
<a>Document</a>.
</li>
<li>
Let <var>implementation</var> be the implementation of <code>config.keySystemConfiguration.keySystem</code>.
Expand Down Expand Up @@ -1136,16 +1095,14 @@ spec: secure-contexts; urlPrefix: https://www.w3.org/TR/secure-contexts/
run the following substeps:
<ol>
<li>
If the <a>global object</a> is of type {{WorkerGlobalScope}},
If the [=/global object=] is of type {{WorkerGlobalScope}},
return a Promise rejected with a newly created {{DOMException}}
whose name is <a>InvalidStateError</a>.
whose name is {{InvalidStateError}}.
</li>
<li>
If the result of running <a>Is the environment settings object
settings a secure context?</a> [[!secure-contexts]] with the
<a>global object's</a> <a>relevant settings object</a> is not
"Secure", return a Promise rejected with a newly created
{{DOMException}} whose name is <a>SecurityError</a>.
If the [=/global object's=] <a>relevant settings object</a> is a
[=non-secure context=], return a Promise rejected with a newly
created {{DOMException}} whose name is {{SecurityError}}.
</li>
</ol>
</li>
Expand Down
6 changes: 3 additions & 3 deletions w3c.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
"group": 115198,
"contacts": [
"tidoust",
"jernoble",
"mounirlamouri"
"marcoscaceres",
"chrisn"
],
"repo-type": "rec-track"
}
}

0 comments on commit e97424c

Please sign in to comment.