Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

@indutny/mac-screen-share

indutny1.7kMIT1.0.13TypeScript support: included

ScreenCaptureKit bindings for Node.js

ScreenCaptureKit, macos, screenshare

readme

@indutny/mac-screen-share

npm

Bindings for macOS ScreenCaptureKit.

Installation

npm install @indutny/mac-screen-share

Usage

import { Stream } from '@indutny/mac-screen-share';

const stream = new Stream({
  width: 1024,
  height: 768,
  frameRate: 10,

  onStart() {},
  onStop(error) {},
  onFrame(frame, width, height, timestamp) {
    // Frame is in Nv12 encoding
    // timestamp is in seconds (not a unix epoch time)
  },
});

// Later
stream.stop();

LICENSE

This software is licensed under the MIT License.