Skip to content

Instantly share code, notes, and snippets.

View kmskrishna's full-sized avatar

Sai Krishna Kothapalli kmskrishna

  • Hyderabad, India
View GitHub Profile
#!/usr/bin/env node
/*
* Inspired by: http://stackoverflow.com/questions/4360060/video-streaming-with-html-5-via-node-js
* Modified from https://gist.github.com/paolorossi/1993068
*/
var http = require('http')
, fs = require('fs')
, util = require('util')
// Load the TCP Library
net = require('net');
// Keep track of the chat clients
var clients = [];
// Start a TCP Server
net.createServer(function (socket) {
// Identify this client