Skip to content
Open
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
8 changes: 4 additions & 4 deletions dist/symple.player.js
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,7 @@

// If there is an active stream then play it now.
if (this.stream) {
this.video.src = URL.createObjectURL(this.stream)
this.video.srcObject = this.stream
this.video.play()
this.setState('playing')
return
Expand All @@ -365,7 +365,7 @@
navigator.getUserMedia(this.options.userMediaConstraints,
function (localStream) { // success
// Play the local video stream and create the SDP offer.
self.video.src = URL.createObjectURL(localStream)
self.video.srcObject = localStream
self.pc.addStream(localStream)
self.pc.createOffer(
function (desc) { // success
Expand Down Expand Up @@ -480,13 +480,13 @@
}
}
this.pc.onaddstream = function (event) {
S.log('symple:webrtc: remote stream added', URL.createObjectURL(event.stream))
S.log('symple:webrtc: remote stream added', event)

// Set the state to playing once candidates have completed gathering.
// This is the best we can do until ICE onstatechange is implemented.
self.setState('playing')

self.video.src = URL.createObjectURL(event.stream)
self.video.srcObject = event.stream
self.video.play()

// Store the active stream
Expand Down
2 changes: 1 addition & 1 deletion dist/symple.player.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion example
Submodule example deleted from 5c4ed1
8 changes: 4 additions & 4 deletions src/symple.player.webrtc.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@

// If there is an active stream then play it now.
if (this.stream) {
this.video.src = URL.createObjectURL(this.stream)
this.video.srcObject = this.stream
this.video.play()
this.setState('playing')
return
Expand All @@ -124,7 +124,7 @@
navigator.getUserMedia(this.options.userMediaConstraints,
function (localStream) { // success
// Play the local video stream and create the SDP offer.
self.video.src = URL.createObjectURL(localStream)
self.video.srcObject = localStream
self.pc.addStream(localStream)
self.pc.createOffer(
function (desc) { // success
Expand Down Expand Up @@ -239,13 +239,13 @@
}
}
this.pc.onaddstream = function (event) {
S.log('symple:webrtc: remote stream added', URL.createObjectURL(event.stream))
S.log('symple:webrtc: remote stream added', event)

// Set the state to playing once candidates have completed gathering.
// This is the best we can do until ICE onstatechange is implemented.
self.setState('playing')

self.video.src = URL.createObjectURL(event.stream)
self.video.srcObject = event.stream
self.video.play()

// Store the active stream
Expand Down