All Projects → sahilchaddha → node-rtsp-recorder

sahilchaddha / node-rtsp-recorder

Licence: other
Records and saves RTSP Video Streams

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to node-rtsp-recorder

rtsp-samsung-tv
Display RTSP streams from IP Cameras on Samsung Smart TV (Tizen TV)
Stars: ✭ 40 (-20%)
Mutual labels:  rtsp, rtsp-stream
rtsp-relay
📽 View an RTSP stream in your web browser using an express.js server
Stars: ✭ 153 (+206%)
Mutual labels:  rtsp, rtsp-stream
streamer
Go Package built around spinning up streaming processes
Stars: ✭ 37 (-26%)
Mutual labels:  rtsp, rtsp-client
GStreamer-Python
Fetch RTSP Stream using GStreamer in Python and get image in Numpy
Stars: ✭ 81 (+62%)
Mutual labels:  rtsp, rtsp-stream
Rtp Streamer
rtp record and rtp streamer
Stars: ✭ 60 (+20%)
Mutual labels:  rtsp, recorder
camera-live-streaming
Camera Live Streaming with Flask and Open-CV
Stars: ✭ 69 (+38%)
Mutual labels:  rtsp, rtsp-stream
rtsp-video-recorder
Provides an API to record RTSP video stream to filesystem.
Stars: ✭ 21 (-58%)
Mutual labels:  rtsp, recorder
plugin-rtsp
rtsp协议实现,接受RTSP推流以及提供拉流转发功能
Stars: ✭ 104 (+108%)
Mutual labels:  rtsp
fapro
Fake Protocol Server
Stars: ✭ 1,338 (+2576%)
Mutual labels:  rtsp
captureSystemAudio
Capture system audio ("What-U-Hear")
Stars: ✭ 29 (-42%)
Mutual labels:  recorder
canvas-record
A one trick pony package to record and download a video from a canvas animation.
Stars: ✭ 64 (+28%)
Mutual labels:  recorder
wyzecam-hls
Converts MP4 files from WyzeCam NFS to HLS stream. Much more stable alternative to RTSP firmware.
Stars: ✭ 58 (+16%)
Mutual labels:  rtsp
rrtsp client
Rust high level RTSP client
Stars: ✭ 12 (-76%)
Mutual labels:  rtsp
gstreamer-rtc-streamer
webrtc streamer based on gstreamer
Stars: ✭ 65 (+30%)
Mutual labels:  rtsp
ZLMediaKit
WebRTC/RTSP/RTMP/HTTP/HLS/HTTP-FLV/WebSocket-FLV/HTTP-TS/HTTP-fMP4/WebSocket-TS/WebSocket-fMP4/GB28181/SRT server and client framework based on C++11
Stars: ✭ 7,790 (+15480%)
Mutual labels:  rtsp
Simple-Voice-Recorder
An easy way of recording any discussion or sounds without ads or internet access
Stars: ✭ 278 (+456%)
Mutual labels:  recorder
v4l2web
V4L2 web interface
Stars: ✭ 20 (-60%)
Mutual labels:  rtsp
ArRtspTool
将RTSP或者NV-RTX上的摄像头流转为webrtc可直接观看的流,延迟低至200ms,Web无插件、Native等全平台低延时拉流
Stars: ✭ 38 (-24%)
Mutual labels:  rtsp
docker-wyze-bridge
RTMP/RTSP/LL-HLS bridge for Wyze cams in a docker container
Stars: ✭ 1,146 (+2192%)
Mutual labels:  rtsp
RTSPhuzz
RTSPhuzz - An RTSP Fuzzer written using the Boofuzz framework
Stars: ✭ 33 (-34%)
Mutual labels:  rtsp

node-rtsp-recorder

RTSP Stream Recorder.

NPM

npm npm CircleCI

Records RTSP Audio/Visual Streams to local disk using ffmpeg

Installation

    $ npm install --save node-rtsp-recorder

Recording Video

    const Recorder = require('node-rtsp-recorder').Recorder

    var rec = new Recorder({
        url: 'rtsp://192.168.1.12:8554/unicast',
        timeLimit: 60, // time in seconds for each segmented video file
        folder: '/Users/sahilchaddha/Sahil/Projects/Github/node-rtsp-recorder/videos',
        name: 'cam1',
    })
    // Starts Recording
    rec.startRecording();

    setTimeout(() => {
        console.log('Stopping Recording')
        rec.stopRecording()
        rec = null
    }, 300000)

If your camera generates empty .mp4 files when recording, you might need to update its audio codec by passing in one usable by your camera (e.g., aac) in the Recorder's constructor. For example:

  var rec = new Recorder({
    url: 'rtsp://192.168.1.12:8554/unicast',
        timeLimit: 60, // time in seconds for each segmented video file
        folder: '/Users/sahilchaddha/Sahil/Projects/Github/node-rtsp-recorder/videos',
        name: 'cam1',
        audioCodec: 'aac'
  })

Recording Audio

    const Recorder = require('node-rtsp-recorder').Recorder

    var rec = new Recorder({
        url: 'rtsp://192.168.1.12:8554/unicast',
        timeLimit: 60, // time in seconds for each segmented video file
        folder: '/Users/sahilchaddha/Sahil/Projects/Github/node-rtsp-recorder/videos',
        name: 'cam1',
        type: 'audio',
    })
    
    rec.startRecording();

    setTimeout(() => {
        console.log('Stopping Recording')
        rec.stopRecording()
        rec = null
    }, 125000)

Capturing Image

    const Recorder = require('node-rtsp-recorder').Recorder

    var rec = new Recorder({
        url: 'rtsp://192.168.1.12:8554/unicast',
        folder: '/Users/sahilchaddha/Sahil/Projects/Github/node-rtsp-recorder/videos',
        name: 'cam1',
        type: 'image',
    })

    rec.captureImage(() => {
        console.log('Image Captured')
    })

Managing Media Directory

    const FileHandler = require('../src/helpers/fileHandler')
    const fh = new FileHandler()
    // RETURNS DIRECTORY SIZE
    fh.getDirectorySize('/Users/sahilchaddha/Sahil/Projects/Github/node-rtsp-recorder/videos/', (err, value) => {
    if (err) {
        console.log('Error Occured')
        console.log(err)
        return true
    }
    console.log('Folder Size is ' + value)
    })
    // REMOVES ALL MEDIA FILES
    fh.removeDirectory('/Users/sahilchaddha/Sahil/Projects/Github/node-rtsp-recorder/videos/*', () => {
    console.log('Done')
    })

Setting custom filename formats

    const Recorder = require('node-rtsp-recorder').Recorder

    var rec = new Recorder({
        url: 'rtsp://192.168.1.12:8554/unicast',
        timeLimit: 60, // time in seconds for each segmented video file
        folder: '/Users/sahilchaddha/Sahil/Projects/Github/node-rtsp-recorder/videos',
        name: 'cam1',
        directoryPathFormat: 'MMM-D-YYYY',
        fileNameFormat: 'M-D-h-mm-ss',
    })
    // Default directoryPathFormat : MMM-Do-YY
    // Default fileNameFormat : YYYY-M-D-h-mm-ss
    // Refer to https://momentjscom.readthedocs.io/en/latest/moment/04-displaying/01-format/ for custom formats.
    // Starts Recording
    rec.startRecording();
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].