p2p-media-loader
p2p-media-loader copied to clipboard
Freeze in Smart TVs browsers
Hello,
Using p2pml.hlsjs.Engine.isSupported()
does not work in some Smart TV browsers I have tested (Samsung Tizen, LG, AOC, Philips, etc). The browser freezes when this line is reached. I had to create a separate page specifically for TVs, with regular player only (no-P2P).
Perhaps isSupported() method could be improved in this aspect, determining with more simple (non WebRTC related) commands if a browser is not capable of P2P due to the use of an old JS engine - before doing the WebRTC check itself?
Can you check what exactly makes the browsers freeze? It doesn't call any browser functions but just checks if API actually exists:
public static isSupported(): boolean {
const browserRtc = (getBrowserRTC as Function)();
return (browserRtc && (browserRtc.RTCPeerConnection.prototype.createDataChannel !== undefined));
}
module.exports = function getBrowserRTC () {
if (typeof window === 'undefined') return null
var wrtc = {
RTCPeerConnection: window.RTCPeerConnection || window.mozRTCPeerConnection ||
window.webkitRTCPeerConnection,
RTCSessionDescription: window.RTCSessionDescription ||
window.mozRTCSessionDescription || window.webkitRTCSessionDescription,
RTCIceCandidate: window.RTCIceCandidate || window.mozRTCIceCandidate ||
window.webkitRTCIceCandidate
}
if (!wrtc.RTCPeerConnection) return null
return wrtc
}
Can you check what exactly makes the browsers freeze?
I have no idea about how to do this. These browsers do not have a console (not I am aware).
A Panasonic TV's browser can't play live stream with p2p-media-loader 0.6.2(hls) but can play with 0.6.1(hls), Maybe ES2017 standard is not support with this tv browser!
Could you release p2p-media-loader with ES6(ES2015)? Thanks!
Can you get the error message from the TV's browser console?
I can't get error message on browser console, that tv is a customer's, I can't touch it!
Me too. Only buffering on smart Tv.
@renatofrota Would you be so kind as to provide example on how you solved HLS streaming on Tizen, webOS... without p2p?