Sunday, September 29, 2013

Wednesday, September 18, 2013

Duff’s Device pattern in JavaScript

Duff’s Device pattern in JavaScript Duff’s Device is a technique of unrolling loop bodies so that each iteration actually does the job of many iterations. Jeff Greenberg is credited with the first published port of Duff’s Device to JavaScript from its original implementation in C. A typical implementation looks like this: //credit: Jeff Greenberg var iterations = Math.floor(items.length / 8), startAt...

Wednesday, September 11, 2013

My WebRTC experiments

10:31 PM Posted by Unknown No comments
I am trying on WebRTC. I will update my progress here. Currently, I am stuck on the following issue. When  I am using RTCDataChannel.send method, I am getting the following error: Uncaught InvalidStateError: An attempt was made to use an object that is not, or is no longer, usable. I am checking if this is because of the createOffer issue. Those who are not familiar with webRTC, you can...