question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support filters without input

See original GitHub issue

I have a video file (with audio) and I want to prepend a few seconds of still background (i.e. black) image without sound. I’m trying to do this with ffmpeg-python, but no success yet.

First thing I stumbled upon is the missing support for the color input file (see my remark here), however, I can work around that by creating a black PNG image and loading that in, e.g. using ffmpeg.input("black.png", t=10).

However, now I need to concatenate the background video with the original video, but I can’t because the background video doesn’t have audio, and concat requires a matching number of audio/video streams. So then I found the aevalsrc filter in ffmpeg, which generates a (silent) audio stream, but I can’t make it work with ffmpeg-python, since it is a filter that doesn’t require input. E.g. this doesn’t work:

stream = ffmpeg.input("black.png", t=10)
stream.filter("aevalsrc", exprs="0", duration=10)

Is there any way to achieve such a thing?

Issue Analytics

  • State:open
  • Created 5 years ago
  • Reactions:1
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

6reactions
jankolkmeiercommented, Jan 4, 2020

Any updates on this?

2reactions
CNugterencommented, Sep 6, 2018

For those also wanting this feature, I have worked around it by creating a simple black .png file and an small .mp3 file with no sound. Then I load them in with ffmpeg.input(filename, ...) and a certain duration. Of course a bit hacky, but this way at least it is possible with ffmpeg-python.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Best NVIDIA FILTERS FOR WARZONE! No INPUT LAG, FPS ...
Best NVIDIA FILTERS FOR WARZONE! No INPUT LAG, FPS DROPS, OR STUTTERS! Nvidia Filters Tutorial! Game Settings:Mouse dpi 400bocw in game ...
Read more >
Quick start: Filter data by using an AutoFilter - Microsoft Support
You can filter on one or more columns of data. With filtering, you can control not only what you want to see, but...
Read more >
Filter data in a spreadsheet - Google Support
If you don't enter a name, the filter view is saved as Filter number, ... You can filter by conditional formatting colors, but...
Read more >
Intro to Find and Filter actions in Shortcuts on Mac
These actions filter photos, reminders, events, and other content passed as input. If no input is passed into Find actions, however, they retrieve...
Read more >
filter - CSS: Cascading Style Sheets - MDN Web Docs
When animated, if both the beginning and end filters have a function list of the same length without url() , each of their...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found