Socket
Socket
Sign inDemoInstall

aperture.js

Package Overview
Dependencies
2
Maintainers
2
Versions
11
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    aperture.js

Record the screen on macOS


Version published
Weekly downloads
6
decreased by-45.45%
Maintainers
2
Created
Weekly downloads
 

Readme

Source

aperture.js

A library for screen recording

XO code style

Install

npm install aperture.js

Usage

const aperture = require('aperture.js')();

const cropArea = {x: 100, y: 100, width: 500, height: 500};

aperture.startRecording({fps: 30, cropArea})
  .then(filePath => setTimeout(stopRecording, 3000));

function stopRecording() {
  aperture.stopRecording()
    .then(console.log); //=> /var/folders/r9/65knbqts47x3yg055cd739qh0000gn/T/tmp-15694AAzbYX1vzi2X.mp4
}

Why

aperture.js was built to fulfill the needs of Kap, providing a JavaScript interface to the best available method for recording the screen. That's why it's currently a wrapper for a Swift script that records the screen using the AVFoundation framework.

But you can use ffmpeg -f avfoundation...

Yes, we can, but the performance is terrible:

Recording the entire screen with ffmpeg -f avfoundation -i 1 -y test.mp4:

ffmpeg

Recording the entire screen with aperture.js:

aperture

Linux and Windows

We want to bring aperture.js to Linux and Windows, but we don't have time and resources for such tasks (we're Mac users), so any help is more than welcome. We just want to enforce two things: performance and quality – doesn't matter how (ffmpeg, custom built native lib, etc) they are achieved.

Upcoming

aperture.js it's in its early days. We want it to have more a lot of features, such as export to GIF, compression options, support for multiple displays, support for audio and much more. Check out our aperture.js issues on Kap to see what we need 😄

FAQs

Last updated on 10 Oct 2016

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc