Socket
Socket
Sign inDemoInstall

ai.natml.natcorder

Package Overview
Dependencies
1
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    ai.natml.natcorder

High performance, cross-platform video recording for Unity Engine.


Version published
Weekly downloads
52
increased by57.58%
Maintainers
1
Install size
6.20 MB
Created
Weekly downloads
 

Readme

Source

NatCorder

NatCorder is a high performance, cross-platform video recording API for Unity Engine. First, create a recorder:

// Create a recorder
var recorder = new GIFRecorder(
    640,  // image width
    480,  // image height
    0.1   // frame duration
);

Next, commit a bunch of video and/or audio frames to the recorder:

// Commit video frames
Texture2D[] frames = ...;
foreach (var frame in frames)
    recorder.CommitFrame(frame.GetPixels32());

And when you're all done, finish writing and use the video as you desire:

// Finish recording
string videoPath = await recorder.FinishWriting();

NatCorder comes with a rich featureset including:

  • Record any texture, anything that can be rendered into a texture, or any pixel data.
  • Record to MP4 videos and animated GIF images.
  • Control recording quality and file size with bitrate and keyframe interval.
  • Record at any resolution. You can specify what resolution recording you want.
  • Get the path to recorded video in device storage.
  • Record game audio with video.
  • Support for recording HEVC videos.
  • Support for Android, iOS, macOS, WebGL, and Windows.

See the online docs to learn more about NatCorder.

Installing NatCorder

First, add the following items to your Unity project's Packages/manifest.json:

{
  "scopedRegistries": [
    {
      "name": "NatML",
      "url": "https://registry.npmjs.com",
      "scopes": ["ai.natml"]
    }
  ],
  "dependencies": {
    "ai.natml.natcorder": "1.9.4"
  }
}

Then retrieve your access key from NatML Hub and add it to your Project Settings:

specifying your access key

Using NatCorder requires an active NatML VideoKit subscription. You can try it out for free, but functionality is limited. See the docs for more info.


Requirements

  • Unity 2021.2+

Supported Platforms

  • Android API Level 24+
  • iOS 14+
  • macOS 10.15+ (Apple Silicon and Intel)
  • Windows 10+ (64-bit only)
  • WebGL:
    • Chrome 91+
    • Firefox 90+

Resources

Keywords

FAQs

Last updated on 28 Feb 2023

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