Skip to content
This repository was archived by the owner on May 22, 2025. It is now read-only.

Screenshots should accept FPS parameter and optimize resulting ffmpeg command #559

@jonathan-fulton

Description

@jonathan-fulton

Currently, generating screenshots creates an ugly ffmpeg command. For instance, doing 1 screenshot / second for a 6 minute video (count = 360) passed ~3000 arguments to ffmpeg when I debugged. It also seemed to error out randomly mentioning something about bit_rate, width, height, etc.

Based on https://trac.ffmpeg.org/wiki/Create%20a%20thumbnail%20image%20every%20X%20seconds%20of%20the%20video it should be possible to use FPS as follows:

ffmpeg -i input.flv -vf fps=1 out%d.png

This worked blazingly fast. 1-2 seconds vs minutes for using node-fluent-ffmpeg when it didn't error out.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions