All Projects → transitive-bullshit → ffmpeg-extract-frames

transitive-bullshit / ffmpeg-extract-frames

Licence: other
Extracts frames from a video using ffmpeg.

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to ffmpeg-extract-frames

Backdoor
A backdoor that runs on Linux and Windows
Stars: ✭ 36 (-28%)
Mutual labels:  screenshot
Screenshot
用于监听Android截屏事件的Demo
Stars: ✭ 15 (-70%)
Mutual labels:  screenshot
DeskViewer
A Java Project for screen sharing based on TCP protocol. Like TeamViewer
Stars: ✭ 23 (-54%)
Mutual labels:  screenshot
goverview
goverview - Get an overview of the list of URLs
Stars: ✭ 93 (+86%)
Mutual labels:  screenshot
jest-puppe-shots
A Jest plugin for creating screenshots of React components with a little help of Puppeteer
Stars: ✭ 86 (+72%)
Mutual labels:  screenshot
fb-post-screenshot
Firefox Web Extension to save Facebook posts as images
Stars: ✭ 18 (-64%)
Mutual labels:  screenshot
GitYourFeedback
Let users submit feedback, with screenshots, directly from your iOS app to Github Issues
Stars: ✭ 60 (+20%)
Mutual labels:  screenshot
omg image
Generate PNG previews for HTML snippets (html/css/js). Any complexity.
Stars: ✭ 28 (-44%)
Mutual labels:  screenshot
browser-shots
A WordPress plugin for taking screenshots of websites using the block editor.
Stars: ✭ 17 (-66%)
Mutual labels:  screenshot
gsu
A general screenshot and upload utility for images, video, and gifs.
Stars: ✭ 18 (-64%)
Mutual labels:  screenshot
canvasTools
Screenshot tool based on canvas
Stars: ✭ 69 (+38%)
Mutual labels:  screenshot
mumemo
Mumemo is screenshot-driven note application.
Stars: ✭ 38 (-24%)
Mutual labels:  screenshot
termux-arch
You can use setupTermuxArch.sh 📲 to install Arch Linux in Termux on Android and Chrome. This setup script will attempt to set Arch Linux up in your Termux environment.
Stars: ✭ 25 (-50%)
Mutual labels:  screenshot
snipped
🖥️ 🖼️ Create fancy screenshots of your code without leaving the editor.
Stars: ✭ 98 (+96%)
Mutual labels:  screenshot
acmpv
使用 mpv 播放带弹幕的 Acfun & Bilibili 视频
Stars: ✭ 27 (-46%)
Mutual labels:  screenshot
mpv crop script
A Lua script to take cropped screenshots in mpv, sans external dependencies
Stars: ✭ 77 (+54%)
Mutual labels:  screenshot
svg-screencast
SVG screencast - animated SVG files from screenshots using CSS animations
Stars: ✭ 28 (-44%)
Mutual labels:  screenshot
laravel-browsershot
Browsershot wrapper for Laravel 5
Stars: ✭ 108 (+116%)
Mutual labels:  screenshot
townshell
For Townscaper, an application providing additional keyboard shortcuts, tools to manipulate .scape files, screen recording
Stars: ✭ 40 (-20%)
Mutual labels:  screenshot
JamTools
JamTools是一个跨平台的小工具集,包含了截屏、录屏、文字识别、各种格式转换、鼠标键盘动作录制播放、文件传输、聊天机器人等功能
Stars: ✭ 73 (+46%)
Mutual labels:  screenshot

ffmpeg-extract-frames

Extracts frames from a video using fluent-ffmpeg.

NPM Build Status JavaScript Style Guide

Install

npm install --save ffmpeg-extract-frames
# or
yarn add ffmpeg-extract-frames

Usage

const extractFrames = require('ffmpeg-extract-frames')

// extract 3 frames at 1s, 2s, and 3.5s respectively
await extractFrames({
  input: 'media/1.mp4',
  output: './screenshot-%i.jpg',
  offsets: [
    1000,
    2000,
    3500
  ]
})

// generated screenshots:
// ./screenshot-1.jpg
// ./screenshot-2.jpg
// ./screenshot-3.jpg
// default behavior is to extract all frames
await extractFrames({
  input: 'media/1.mp4',
  output: './frame-%d.png'
})

// generated screenshots:
// ./frame-1.png
// ./frame-2.png
// ...
// ./frame-100.png

API

extractFrames(options)

Extracts one or more frames from a video file. Returns a Promise for when all frames have been written.

There are several options for specifying which frames to extract, namely timestamps, offsets, fps, and numFrames. The default behavior if you don't specify any of these options is to extract all frames from the input.

options

input

Type: String Required

Path or URL to a video file.

output

Type: String Required

Output file pattern.

Note that for timestamps or offsets, the pattern should include a %i or %s (details).

For any other call, you should use the %d format specifier. I know this is confusing, but it's how fluent-ffmpeg works under the hood.

offsets

Type: Array<Number>

Array of seek offsets to take the screenshot from in milliseconds.

timestamps

Type: Array<Number|String>

Same as fluent-ffmpeg's screenshots.timestamps.

fps

Type: Number

Frames per second to output.

numFrames

Type: Number

Output a specific number of frames. The input video's frames will be skipped such that only this number of frames are output.

log

Type: Function Default: noop

Optional function to log the underlying ffmpeg command (like console.log).

ffmpegPath

Type: String

Specify a path for the ffmpeg binary.

Related

License

MIT © Travis Fischer

Support my OSS work by following me on twitter twitter

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].