-
-
Notifications
You must be signed in to change notification settings - Fork 978
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
[WIP] Implementation of .renegotiate and .negotiate API #72
Conversation
NOTE: I've seen that there are linting issues on the CD, I will fix them just before landing the PR. |
trim_trailing_whitespace = false | ||
|
||
[COMMIT_EDITMSG] | ||
max_line_length = 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please don't commit this file
I think it's a mistake to stop using the onnegotiationneeded event. That was required for things to work for me before -- has that changed? |
I have to finish this up, the only issue I had was with the Firefox implementation, tests were flawless on chrome. Seen that you've closed the PR, are you still interested in having renegotiation here? |
Sorry for closing the PR -- that was an accident. Before I can merge this, you need to fix the merge conflicts, fix the code style, and fix it on Firefox. Looks like you also might need to add:
to the top of the See: https://www.webrtc-experiment.com/docs/how-to-switch-streams.html |
Also, the test style is kind of weird. Can you clean it up a bit? |
var test = require('tape') | ||
|
||
var getUserMedia = typeof navigator !== 'undefined' && ( | ||
navigator.webkitGetUserMedia && function ( options, fulfill, reject ) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just use if statements. That would be much simpler.
@cusspvz Are you still working on it ? |
Hi @cusspvz , are you not interested in this anymore? |
@MatthieuLemoine @princemaple I am but not for now, but can arrange some time to inject some changes on the PR. Also, seems firefox only accepts one data stream per RTConnection. @feross if I implement |
addStream is going to be deprecated in future versions. Firefox supports addTrack. They have a migration plan with chrome back-support here https://developer.mozilla.org/en-US/docs/Web/API/RTCPeerConnection/addStream |
I think we should leave addStream in the simple-peer API. It's much simpler than adding individual tracks (although a secondary track API couldn't hurt). We already use addTrack internally. |
addStream is being deprecated. If simple-peer wants to support an addStream that simply calls addTracks on each track then that would be fine. But long term the API is going away. |
Closing due to #250 |
.renegotiate
.negotiate
negotiate
event.addStream
.removeStream
.addDataStream
- have a question if we should allow multiple datastreams.removeDataStream
- [x] Added
.editorconfig
- [x] Added
node_modules/
to.gitignore
and.npmignore
Current stage:
Related issues: