Skip to content

Stream any RTSP stream and output to websocket for consumption by jsmpeg. 📹

Notifications You must be signed in to change notification settings

Segware/node-rtsp-stream-es6

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

node-rtsp-stream-es6

First of all, it's a fork of node-rtsp-stream

Differences with the original module

  • Written in ES6 instead of CoffeeScript
  • Github repository

Description

Stream any RTSP stream and output to WebSocket for consumption by jsmpeg. HTML5 streaming video!

Requirements

You need to download and install FFMPEG.

Installation

npm i node-rtsp-stream-es6

Server

const Stream = require('videoStream')

const options = {
  name: 'streamName',
  url: 'rtsp://184.72.239.149/vod/mp4:BigBuckBunny_115k.mov',
  port: 5000
}

stream = new Stream(options)

stream.start()

Client

const WebSocket = require('ws')
const ws = new WebSocket('ws://localhost:5000')

ws.on('open', () => {
  console.log('Connected to stream')
})

ws.on('message', (data, flags) => {
  console.log(data)
})

You can find a live stream JSMPEG example here : https://github.com/phoboslab/jsmpeg/blob/master/view-stream.html

About

Stream any RTSP stream and output to websocket for consumption by jsmpeg. 📹

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%