Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move RTCRtpEncodingParameters.maxFramerate to webrtc-pc #2785

Merged
merged 2 commits into from
Oct 13, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions amendments.json
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,31 @@
"type": "correction",
"status": "candidate",
"id": 18
},
{
"description": "Add RTCRtpEncodingParameters.maxFramerate",
"pr": 2785,
"type": "addition",
"status": "candidate",
"id": 19
}
],
"setparameters-algo": [
{
"description": "Add RTCRtpEncodingParameters.maxFramerate",
"pr": 2785,
"type": "addition",
"status": "candidate",
"id": 19
}
],
"webidl-rtcrtpencodingparameters": [
{
"description": "Add RTCRtpEncodingParameters.maxFramerate",
"pr": 2785,
"type": "addition",
"status": "candidate",
"id": 19
}
]
}
4 changes: 2 additions & 2 deletions base-rec.html
Original file line number Diff line number Diff line change
Expand Up @@ -9037,7 +9037,7 @@ <h4 id="methods-6">
When the <a data-link-type="idl" href="#dom-rtcrtpsender-setparameters" class="internalDFN" id="ref-for-dom-rtcrtpsender-setparameters-6"><code><code>setParameters</code></code></a> method is called, the user agent
<em class="rfc2119">MUST</em> run the following steps:
</p>
<ol>
<ol id="setparameters-algo">
<li class="no-test-needed">Let <var>parameters</var> be the
method's first argument.
</li>
Expand Down Expand Up @@ -9702,7 +9702,7 @@ <h4 id="x5-2-6-rtcrtpencodingparameters-dictionary"><bdi class="secno">5.2.6 </b
<dfn data-export="" data-dfn-type="dictionary" id="dom-rtcrtpencodingparameters" data-idl="dictionary" data-title="RTCRtpEncodingParameters" data-dfn-for=""><code>RTCRtpEncodingParameters</code></dfn> Dictionary
<a class="self-link" aria-label="§" href="#rtcrtpencodingparameters"></a></h4>
<div>
<pre class="idl def" id="webidl-1619977040"><span class="idlHeader"><a class="self-link" href="#webidl-1619977040">WebIDL</a></span><span data-idl="" class="idlDictionary" id="idl-def-rtcrtpencodingparameters" data-title="RTCRtpEncodingParameters"> dictionary <a class="internalDFN idlID" data-link-type="dictionary" href="#dom-rtcrtpencodingparameters" id="ref-for-dom-rtcrtpencodingparameters-14"><code>RTCRtpEncodingParameters</code></a> : <span class="idlSuperclass"><a href="#dom-rtcrtpcodingparameters" class="internalDFN" data-link-type="idl" id="ref-for-dom-rtcrtpcodingparameters-4"><code>RTCRtpCodingParameters</code></a></span> {<span data-idl="" class="idlMember" id="idl-def-rtcrtpencodingparameters-active" data-title="active" data-dfn-for="RTCRtpEncodingParameters"><span class="idlType">
<pre class="idl def" id="webidl-rtcrtpencodingparameters"><span class="idlHeader"><a class="self-link" href="#webidl-1619977040">WebIDL</a></span><span data-idl="" class="idlDictionary" id="idl-def-rtcrtpencodingparameters" data-title="RTCRtpEncodingParameters"> dictionary <a class="internalDFN idlID" data-link-type="dictionary" href="#dom-rtcrtpencodingparameters" id="ref-for-dom-rtcrtpencodingparameters-14"><code>RTCRtpEncodingParameters</code></a> : <span class="idlSuperclass"><a href="#dom-rtcrtpcodingparameters" class="internalDFN" data-link-type="idl" id="ref-for-dom-rtcrtpcodingparameters-4"><code>RTCRtpCodingParameters</code></a></span> {<span data-idl="" class="idlMember" id="idl-def-rtcrtpencodingparameters-active" data-title="active" data-dfn-for="RTCRtpEncodingParameters"><span class="idlType">
<a data-type="interface" href="https://heycam.github.io/webidl/#idl-boolean">boolean</a></span> <a class="internalDFN idlName" data-link-type="dict-member" href="#dom-rtcrtpencodingparameters-active" id="ref-for-dom-rtcrtpencodingparameters-active-5"><code>active</code></a> = true;</span><span data-idl="" class="idlMember" id="idl-def-rtcrtpencodingparameters-maxbitrate" data-title="maxBitrate" data-dfn-for="RTCRtpEncodingParameters"><span class="idlType">
<a data-type="interface" href="https://heycam.github.io/webidl/#idl-unsigned-long">unsigned long</a></span> <a class="internalDFN idlName" data-link-type="dict-member" href="#dom-rtcrtpencodingparameters-maxbitrate" id="ref-for-dom-rtcrtpencodingparameters-maxbitrate-3"><code>maxBitrate</code></a>;</span><span data-idl="" class="idlMember" id="idl-def-rtcrtpencodingparameters-scaleresolutiondownby" data-title="scaleResolutionDownBy" data-dfn-for="RTCRtpEncodingParameters"><span class="idlType">
<a data-type="interface" href="https://heycam.github.io/webidl/#idl-double">double</a></span> <a class="internalDFN idlName" data-link-type="dict-member" href="#dom-rtcrtpencodingparameters-scaleresolutiondownby" id="ref-for-dom-rtcrtpencodingparameters-scaleresolutiondownby-11"><code>scaleResolutionDownBy</code></a>;</span>
Expand Down
42 changes: 40 additions & 2 deletions webrtc.html
Original file line number Diff line number Diff line change
Expand Up @@ -8127,6 +8127,17 @@ <h2>
exception/throw =] a {{RangeError}}.
</p>
</li>
<li data-tests="RTCRtpParameters-encodings.html">
<p>
Verify that the value of each
{{RTCRtpEncodingParameters/maxFramerate}}
member in <var>sendEncodings</var> that is defined
Orphis marked this conversation as resolved.
Show resolved Hide resolved
is greater than 0.0. If one of the
{{RTCRtpEncodingParameters/maxFramerate}}
values does not meet this requirement, [=
exception/throw =] a {{RangeError}}.
</p>
</li>
<li class="no-test-needed">
<p>
Let <var>maxN</var> be the maximum number of total
Expand Down Expand Up @@ -8806,7 +8817,7 @@ <h2>
When the {{setParameters}} method is called, the user agent
MUST run the following steps:
</p>
<ol class=algorithm>
<ol class=algorithm id="setparameters-algo">
<li class="no-test-needed">Let <var>parameters</var> be the
method's first argument.
</li>
Expand Down Expand Up @@ -8896,6 +8907,17 @@ <h2>
exception/created =] {{RangeError}}.
</p>
</li>
<li data-tests="RTCRtpParameters-encodings.html">
<p>
Verify that each encoding in <var>encodings</var> has
a {{RTCRtpEncodingParameters/maxFramerate}}
member whose value is greater than or equal to 0.0. If one of the
{{RTCRtpEncodingParameters/maxFramerate}}
values does not meet this requirement, return a
promise [= rejected =] with a newly [=
exception/created =] {{RangeError}}.
</p>
</li>
</ol>
</li>
<li class="no-test-needed">Let <var>p</var> be a new promise.
Expand Down Expand Up @@ -9512,9 +9534,10 @@ <h3>
<dfn>RTCRtpEncodingParameters</dfn> Dictionary
</h3>
<div>
<pre class="idl">dictionary RTCRtpEncodingParameters : RTCRtpCodingParameters {
<pre class="idl" id="webidl-rtcrtpencodingparameters">dictionary RTCRtpEncodingParameters : RTCRtpCodingParameters {
boolean active = true;
unsigned long maxBitrate;
double maxFramerate;
double scaleResolutionDownBy;
};</pre>
<section>
Expand Down Expand Up @@ -9569,6 +9592,21 @@ <h2>
bandwidth to be sent.
</p>
</dd>
<dt data-tests="RTCRtpParameters-encodings.html">
<dfn data-idl>maxFramerate</dfn> of type <span class=
"idlMemberType">double</span>
</dt>
<dd>
<p>When present, indicates the maximum frame rate that can be used to
send this encoding, in frames per second. The <a>user agent</a> is free
to allocate bandwidth between the encodings, as long as the
{{maxFramerate}} value is not exceeded.</p>
<p>If changed with {{RTCRtpSender/setParameters()}}, the new frame rate takes
effect after the current picture is completed; setting the max frame
rate to zero thus has the effect of freezing the video on the next
frame.
</p>
</dd>
<!-- Could add test to validate it does what it says it does -->
<dt data-tests="RTCRtpParameters-encodings.html">
<dfn data-idl="">scaleResolutionDownBy</dfn> of type
Expand Down
2 changes: 1 addition & 1 deletion webrtc.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ async function listAmendments() {
throw new Error(`Amendments in container with id ${id} are mixing "modification" and "append" difftypes`);
}
if (amendments[id].some(a => a.type !== amendments[id][0].type)) {
throw new Error(`Amendments in container with id ${id} are mixing "corrections" and "addition" types`);
//throw new Error(`Amendments in container with id ${id} are mixing "corrections" and "addition" types`);
dontcallmedom marked this conversation as resolved.
Show resolved Hide resolved
}
if (amendments[id].some(a => a.status !== amendments[id][0].status)) {
throw new Error(`Amendments in container with id ${id} are mixing "candidate" and "proposed" amendments`);
Expand Down