Skip to content

Commit f616461

Browse files
authored
Remove script transform variant API (#64)
1 parent 701cc7e commit f616461

File tree

1 file changed

+2
-24
lines changed

1 file changed

+2
-24
lines changed

index.bs

Lines changed: 2 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -60,9 +60,7 @@ decoder part of a codec.
6060
The Streams definition doesn't use WebIDL much, but the WebRTC spec does.
6161
This specification shows the IDL extensions for WebRTC.
6262

63-
It uses an extension to RTCConfiguration in order to notify the
64-
{{RTCPeerConnection}} that insertable streams will be used, and uses
65-
an additional API on {{RTCRtpSender}} and {{RTCRtpReceiver}} to
63+
It uses an additional API on {{RTCRtpSender}} and {{RTCRtpReceiver}} to
6664
insert the processing into the pipeline.
6765

6866
<pre class="idl">
@@ -72,21 +70,14 @@ dictionary RTCInsertableStreams {
7270
WritableStream writable;
7371
};
7472

75-
// New fields in RTCConfiguration
76-
partial dictionary RTCConfiguration {
77-
boolean encodedInsertableStreams = false;
78-
};
79-
8073
typedef (SFrameTransform or RTCRtpScriptTransform) RTCRtpTransform;
8174

8275
// New methods for RTCRtpSender and RTCRtpReceiver
8376
partial interface RTCRtpSender {
84-
RTCInsertableStreams createEncodedStreams();
8577
attribute RTCRtpTransform? transform;
8678
};
8779

8880
partial interface RTCRtpReceiver {
89-
RTCInsertableStreams createEncodedStreams();
9081
attribute RTCRtpTransform? transform;
9182
};
9283
</pre>
@@ -101,7 +92,6 @@ argument, ensure that the codec is disabled and produces no output.
10192
### Stream creation ### {#stream-creation}
10293

10394
At construction of each {{RTCRtpSender}} or {{RTCRtpReceiver}}, run the following steps:
104-
1. Initialize [=this=].`[[Streams]]` to null.
10595
2. Initialize [=this=].`[[transform]]` to null.
10696
3. Initialize [=this=].`[[readable]]` to a new {{ReadableStream}}.
10797
4. <a dfn for="ReadableStream">Set up</a> [=this=].`[[readable]]`. [=this=].`[[readable]]` is provided frames using the [=readEncodedData=] algorithm given |this| as parameter.
@@ -111,24 +101,12 @@ At construction of each {{RTCRtpSender}} or {{RTCRtpReceiver}}, run the followin
111101
8. Set [=this=].`[[writable]]`.`[[owner]]` to |this|.
112102
9. Initialize [=this=].`[[pipeToController]]` to null.
113103
10. Initialize [=this=].`[[lastReceivedFrameTimestamp]]` to zero.
114-
11. If the {{RTCPeerConnection}}'s configuration does not have {{RTCConfiguration/encodedInsertableStreams}} set to "true", [=queue a task=] to run the following steps:
104+
11. [=Queue a task=] to run the following steps:
115105
1. If [=this=].`[[pipeToController]]` is not null, abort these steps.
116106
2. Set [=this=].`[[pipeToController]]` to a new {{AbortController}}.
117107
<!-- FIXME: Use pipeTo algorithm when available. -->
118108
3. Call <a href="https://streams.spec.whatwg.org/#readable-stream-pipe-to">pipeTo</a> with [=this=].`[[readable]]`, [=this=].`[[writable]]`, preventClose equal to true, preventAbort equal to true, preventCancel equal to true and [=this=].`[[pipeToController]]`.signal.
119109

120-
The <dfn method for="RTCRtpSender">createEncodedStreams()</dfn> method steps are:
121-
122-
1. If the {{RTCPeerConnection}}'s configuration does not have {{RTCConfiguration/encodedInsertableStreams}} set to "true", throw an "{{InvalidAccessError}}" {{DOMException}} and abort these steps.
123-
2. If the data source does not permit access, throw an "{{InvalidAccessError}}" {{DOMException}} and abort these steps.
124-
3. If [=this=].`[[Streams]]` is not null, throw an "{{InvalidAccessError}}" {{DOMException}}.
125-
4. If [=this=].`[[pipeToController]]` is not null, throw an "{{InvalidAccessError}}" {{DOMException}}.
126-
5. Set [=this=].`[[Streams]]` to an {{RTCInsertableStreams}} object.
127-
6. Set [=this=].`[[Streams]]`.{{RTCInsertableStreams/readable}} to [=this=].`[[readable]]`.
128-
7. Set [=this=].`[[Streams]]`.{{RTCInsertableStreams/writable}} to [=this=].`[[writable]]`.
129-
8. Enable the encoded data source.
130-
10. Return [=this=].`[[Streams]]`.
131-
132110
### Stream processing ### {#stream-processing}
133111

134112
The <dfn>readEncodedData</dfn> algorithm is given a |rtcObject| as parameter. It is defined by running the following steps:

0 commit comments

Comments
 (0)