-
Notifications
You must be signed in to change notification settings - Fork 5
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
Should RtpSendStream/RtpReceiveStream be transferable? #36
Comments
Here is an example of how would look like this API without transferable.
|
Tentative evaluation of pros and cons: Pros for transferable approach
Cons for transferable approach
Pros for non transferable approach
Cons for non transferable approach
|
I would add a Pro for transferability / Con for non-transferable that this uses a standard JS pattern with which developers are already familiar, rather than needing to learn the semantics of another api-specific "one off transfer". |
Yes and no. Second, the semantics of the "one off transfer" are simpler to understand. With the transferability approach, web developers may need to understand:
In that same vein, if we want to extend these objects in the future, we would need to design these API extensions with transferability as a constraint. |
Pros for the transferable approach:
Cons for the one-off approach:
We have already tackled many of the transferable-approach issues when dealing with transfer of tracks. |
How so? in both approaches, the web application is able to decide whether it wants to send/receive packets in a worker/thread A or in a worker/thread B. |
One thing that came up when thinking about how to implement a JS level pacer. The app should have control over the order in which packets are put onto the network, and having Lets say for example if you want to send a packet from stream A and stream B within a short interval. Now the pacer can post to woker A and worker B so that AFAICT the solution to this would be to have all |
explainer-use-case-1.md sets the two objects as transferable.
The main benefit is to allow to transfer these objects to workers so that packet processing is done there.
Another approach is to consider how it is being done in webrtc encoded transform or for encoded source.
It would be good to compare the pros and cons of both approaches.
The text was updated successfully, but these errors were encountered: