Is it possible to detect the finish of a youtube buffering through javascript? Here http://code.google.com/intl/de-DE/apis/youtube/js_api_reference.html are a lot of methods but no one has an event that says "finished with buffering".
var ytplayer;
function onYouTubePlayerReady(playerId) {
ytplayer = document.getElementById("myytplayer");
checkBuffer();
}
function checkBuffer(){
if(ytplayer.getVideoBytesLoaded() == ytplayer.getVideoBytesTotal()){
alert('Buffer Complete!');
}else{
var t = setTimeout(function(){
Editor.split();
},1000);
}
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With