WebRTC - Flash interoperability

Ask questions about the JavaScript API here

WebRTC - Flash interoperability

Postby victorsb » Thu Nov 08, 2012 8:02 pm

Hi guys,

Congrats on your webrtc tokbox release :) here at MashMeTV we started working a few hours ago ( btw yes in Spain is late VERY late xD ) and we have a testing version working with WebRTC.

It works great audio and video quality felt amazing, BUT is there a way to interoperate between the new webrtc version? and the old flash one?

Sadly no all MashMeTV users are using chrome (shame on them)

Thanks!
Was this post helpful? (1)
victorsb
 
Posts: 33
Joined: Tue Sep 20, 2011 3:21 pm
Thumbs Up: 3

Re: WebRTC - Flash interoperability

Postby janine » Fri Nov 09, 2012 11:50 am

HI Victor! That was fast!! The current webrtc version does not fallback to flash (sorry!!!). I am going to copy paste this response on our blog from Ankur on my team, since it's better than anything I can say:

There is no automatic fallback right now. An earlier version of our Labs releases did support fallback from WebRTC -> Flash, but we decided doing without that helped to get the technology out there sooner and see how our developers actually used it. That fallback would detect if any single client that was connected didn't support WebRTC, then all connected clients would fallback to Flash, and therefore they were all in the same session. Sessions were not mixed. Right now the way to achieve this is exactly what you said: feature detect and load the appropriate library. Stay tuned, new features like this may land pretty soon as we learn more about users.
Was this post helpful? (0)
janine
 
Posts: 1578
Joined: Thu May 05, 2011 7:10 pm
Thumbs Up: 19

Re: WebRTC - Flash interoperability

Postby victorsb » Fri Nov 09, 2012 1:26 pm

Thanks for the fast answer :)

I will wait then for some fallback solution in that matter or let's hope that all browsers provider put webrtc where it should be :)

PS: the fast implementation was actually pretty easy almost everything worked out of the box.

Regards
Was this post helpful? (0)
victorsb
 
Posts: 33
Joined: Tue Sep 20, 2011 3:21 pm
Thumbs Up: 3

Re: WebRTC - Flash interoperability

Postby shuoyanz » Sat Nov 10, 2012 12:36 pm

Hello, can't wait to implement the WebRTC version on our site, but we wouldn't implement it without fallback. Hope the feature comes soon!
Was this post helpful? (0)
shuoyanz
 
Posts: 4
Joined: Wed Aug 29, 2012 11:48 pm
Thumbs Up: 0

Re: WebRTC - Flash interoperability

Postby kmacinni » Tue Jan 29, 2013 5:38 pm

Also looking forward to this - any ETA on interop? What's the current state of the art for mixing WebRTC and Flash clients, including selecting an OpenTok library based on their capabilities?
Was this post helpful? (0)
kmacinni
 
Posts: 8
Joined: Fri Nov 16, 2012 1:26 pm
Thumbs Up: 0

Re: WebRTC - Flash interoperability

Postby jtsai » Wed Feb 27, 2013 4:15 pm

No flash-webrtc interop is planned anymore. There is not enough demand/ not enough resources to implement such a thing.

Sorry,
John
Was this post helpful? (0)
Very helpful resource: Devs Checklist
Examples with OpenTok: Examples
User avatar
jtsai
 
Posts: 1985
Joined: Wed Sep 14, 2011 3:00 pm
Thumbs Up: 157

Re: WebRTC - Flash interoperability

Postby redo » Mon Mar 11, 2013 9:09 am

Since "No flash-webrtc interop is planned anymore" you can implement it by dynamically loading the right library:

<script src='http://static.opentok.com/webrtc/v2.0/js/TB.min.js' ></script>
<script type="text/javascript">var isVB = false</script>
<script LANGUAGE="VBSCRIPT">isVB = true</script>
<script type="text/javascript">
if (TB.checkSystemRequirements() == 0) //cannot use html5 chat, switching to flash - load a js lib for flash
{
TB = null;
loadScript('http://static.opentok.com/v0.91.63/js/TB.min.js', loadSolo);
}
else
{
//proceed with webrtc
loadSolo();
}

function loadSolo()
{
TB.addEventListener("exception", exceptionHandler); //and do whatever else you need to do
}

function loadScript(sScriptSrc, callback)
{
var scrWrapper = document.getElementById('scrWrapper'); //make sure you create this div in a page before the code executes
var oScript = document.createElement('script');
oScript.type = 'text/javascript';
oScript.src = sScriptSrc;
scrWrapper.appendChild(oScript);
if (!isVB)
{
oScript.onload = callback;
}
else
{ //for iE
oScript.onreadystatechange = function()
{
if (this.readyState == 'complete')
{
callback();
}
};
}
}
</SCRIPT>

Just make sure the browsers understand the same media file type - use canPlayType.
All the best,
Peter
Was this post helpful? (1)
redo
 
Posts: 11
Joined: Sat Mar 09, 2013 2:43 pm
Thumbs Up: 1


Return to JavaScript



Who is online

Users browsing this forum: No registered users and 1 guest

cron