0.0.2 • Published 7 years ago

t-rec v0.0.2

Weekly downloads
2
License
MIT
Repository
github
Last release
7 years ago

T-Rec

FFmpeg-powered screen recording module for Node.js

Requires FFmpeg installed in the PATH

Currently supports Windows and Linux

Usage

  1. Install module using npm install t-rec
  2. Require the module
      let Recorder = require('t-rec')
  3. Recorder.Record(options) - function: returns Promise

    • options - Object
      • fps - Integer : The FPS at which the screen will be recorded
      • output - String : The path where the recorded video will be saved at
      • crop - Object
        • x - Integer : Horizontal offset value
        • y - Integer : Vertical offset value
        • width - Integer : Width of the video
        • height - Integer : Height of the video
  4. Example Code:

    Recorder.Record({
      fps: 30,
      output: 'output.mp4',
      crop: {
        x: 0,
        y: 0,
        width: 640,
        height: 480
      }
    }).then((done) => {
      console.log(done)
    }).catch((err) => {
      // ENOENT if FFmpeg is not installed
      console.log(err)
    })

Tasks

  • Windows support
  • Linux support
  • macOS support
  • Audio support

MIT © 2018 Stego