Thanks for the examples! I found them a helpful part of the explainer.
But they refer to the "Encoded Transform API", presumably webrtc-encoded-transform without using any of its APIs, (instead using nonstandard createEncodedStreams). This should be fixed to avoid confusion.
This should help solve #13 and address feedback from at least @jesup and myself that this API should be worker-first.
E.g. a minimum update of the existing examples to spec might yield:
Example: Send with custom packetization
// main.js
const pc = new RTCPeerConnection();
const rtpTransport = pc.createRtpTransport();
const transform = new RTCRtpScriptTransform(worker, {rtpTransport}, [rtpTransport]);
for (const sender of pc.getSenders()) {
sender.transform = transform;
}
...except why expose rtpTransport on main thread at all? E.g. why not:
I'm not necessarily condoning this as a final shape — it begs other questions like what is the type of a packet and why not reuse the transformer's existing writable? — but developing off of standard APIs I think is the right step forward.
Thanks for the examples! I found them a helpful part of the explainer.
But they refer to the "Encoded Transform API", presumably webrtc-encoded-transform without using any of its APIs, (instead using nonstandard
createEncodedStreams
). This should be fixed to avoid confusion.This should help solve #13 and address feedback from at least @jesup and myself that this API should be worker-first.
E.g. a minimum update of the existing examples to spec might yield:
Example: Send with custom packetization
...except why expose
rtpTransport
on main thread at all? E.g. why not:I'm not necessarily condoning this as a final shape — it begs other questions like what is the type of a packet and why not reuse the transformer's existing
writable
? — but developing off of standard APIs I think is the right step forward.