FFmpeg is a free software project that produces libraries and programs for handling multimedia data. The most notable parts of FFmpeg are libavcodec, an audio/video codec library used by several other projects, libavformat, an audio/video container mux and demux library, and the ffmpeg command line ...

learn more… | top users | synonyms

5
votes
1answer
5k views

ffmpeg drawtext filter - create transparent background with text

I am currently working with the drawtext filter. So far I have only been successful with drawtext option configurations to use the right font and place the text horizontally centered. How could i get ...
13
votes
4answers
28k views

How to losslessly encode a jpg image sequence to a video in ffmpeg?

I have a large set of jpgs that I want to convert to a video losslessly (or, at the very least, very close to losslessly as long as the encoding time isn't much higher than otherwise). Naively, I ...
3
votes
1answer
1k views

Correct lens distortion with ffmpeg

It seems to be possible to correct lens distortion with ffmpeg. According to the manual you can adjust K1 and K2 values. What this means? How to use it correctly? Example still image - captured with ...
3
votes
1answer
4k views

What CRF or settings I should choose for h265 in order to achieve a similiar quality of h264?

I'm doing some experiments with HEVC x265. I have a raw footage and the quality of details of h264 with same CRF setting looks better than h265. Shouldn't be the opposite? Maybe my setup isn't the ...
60
votes
1answer
69k views

How can I crop a video with ffmpeg?

I have an MP4 file of a screen recording that I need to crop down. How can I accomplish this without using expensive tools like Adobe Premier or Final Cut? I prefer ffmpeg because I have used it ...
2
votes
1answer
680 views

ffmpeg - video with timer

I am currently working with the drawtext and drawbox filters to recreate a similar video appearance to what is shown below in the image. I am trying to see of a possible ways to add a count down timer ...
1
vote
1answer
539 views

Can I run this in one command line (ffmpeg)

I used this command ffmpeg -i thevideo.mp4 -c:a copy -vf 'drawbox= : x=0 : y=0 : color=invert:enable=between(t\,11\,39)' output.mp4 but it runs very slow. So, I took another approach, I copy first ...
11
votes
1answer
28k views

How do I change frame size, preserving width (using ffmpeg)?

I'm new to this StackExchange site, and to using the ffmpeg encoder. I have a video that is 720x480 (3:2) that I would like to change to 720x406 (16:9) to match the other videos I have for a site. I ...
13
votes
4answers
19k views

How can I convert .MTS file (AVCHD) to .mp4 by ffmpeg without re-encoding H264 video stream?

Note: I posted same question to stackoverflow a short time before, when I have not found this comunity yet. I repost this since the question is more suitable to this community. 1. What I tried I ...
10
votes
4answers
9k views

How to get FFMPEG to join non-sequential image files? (skip by 3s)

I have a bunch of images, that follow this pattern. 0001.png 0004.png 0007.png 0010.png 0013.png 0016.png 0019.png ... They're in the correct order, but FFMPEG ignores anything after the first file,...
8
votes
1answer
16k views

Add an image in front of video using ffmpeg

I have many videos and I need to put an image in front of them for about 5 seconds, but adding it manually and rendering it each time would take really long, so I am asking if it is possible to do so ...
1
vote
2answers
6k views

How do I recover truncated AVI/DV video?

Short version: I believe I have truncated but otherwise valid AVI/DV files that won't play in any player I've tried (Adobe Premiere, MPC HC, VLC). I assume the stream data is intact but truncated, and ...
6
votes
2answers
4k views

What is the difference between ffmpeg and ffmbc now?

Two years ago I've used ffmbc to encode videos to prores, but nowadays ffmpeg also supports prores and avchd. What is the difference between ffmpeg and ffmbc now?
4
votes
3answers
1k views

creating a lossless mp4 screencast

I'm trying to create a screencast for playback on the web. Would like to use h.264, webm, and ogg. The source files are in the Apple Animation codec, and they look perfectly accurate. However when I ...
1
vote
0answers
62 views

How to produce a zoom animation of a video source with ffmpeg?

I'd like to create a zoom-in animation over numerous frames of a video clip. I've tried a couple of approaches without much luck. ffmpeg -i test-10s.mp4 -vf "zoompan=z='zoom+0.001'" zoompan-10s.mp4 ...
4
votes
1answer
122 views

Top and tail GoPro video based on volume

I'm thinking of using ffmpeg to automate a simple video task. I have lots of action videos that go like this, quiet/boring -> loud/exciting -> quiet/boring. Allowing for a few seconds at the start ...
4
votes
1answer
1k views

Video converted by FFMPEG has a different duration, why?

I convert videos using FFMPEG. My goal is to convert them to the MP4 container format (MPEG-4 Part 14) with AAC-encoded audio stream and MPEG-4 part 10-encoded video stream. I use the following line ...
4
votes
1answer
50 views

Extracting video fields Respectively

Extracting individual video fields is my previews question. Based on the Mulvya's answer I can extract the top fields (only) or the bottom fields (only) individual. Now, I need to extract the video ...
3
votes
2answers
2k views

FFMpeg Encoding and Core Usage

We have developed an application to transcode source .mov files into .ogg, .mp4 and .webm output. It is currently running on AWS EC2 instance g2.8xlarge. It is working (yay!). My question: Even ...
3
votes
1answer
253 views

Using h264 in loseless mode brings small unexpected results

I got curious on ffmpeg screen capture capabilities and started messing around with a simple realtime capture test in h264. ffmpeg -f dshow -i video="screen-capture-recorder" -video_size 1920x1080 -...
2
votes
1answer
286 views

Crossfading audio at beginning and ending of video

The html5 video tag has a loop attribute. When playing a video in a continuous loop, it doesn't do this seamlessly. I hear cracks and pops at the beginning. With ffmpeg I am able to trim .05 seconds ...
2
votes
1answer
321 views

Streamable Container for HEVC (H.265)

flv is a container which can be used to stream videos while they are being encoded. flv supports h.264 codec. However, flv doesn't support hevc codec. Is there any container for hevc which is ...
1
vote
1answer
225 views

ffmpeg Cut a media preserving all streams but also all metadata, timecodes and everything else

Today I wanted to obtain a ts file cut preserving everything, so I tried with this command: ffmpeg -i "original.ts" -map 0 -c copy -t 00:30:0.0 -threads 1 "cutted.ts" The resulting file have ...
1
vote
1answer
31 views

Identifying source of audio drift between camcorder and recording PC

I'm recording our church's sermons using a standard consumer-grade camcorder (Handycam HDR-CX380). Depending on mixer circumstances (our church moves around a lot), I'll either run a line from our ...
1
vote
1answer
115 views

Unable to hardcode subtitles in FFmpeg on Mac to mov

I would like to hardcode subtitles using FFmpeg, I'm trying to do this using the following command: ffmpeg -i grdedFinal.mov -vf subtitles=portSbs.srt gradedFinalwithSubs.mov which returns the ...
1
vote
2answers
619 views

Why does quality degrade so much if just cutting video with ffmpeg?

I have tried to cut video with the following command ffmpeg -i "Вспомнить все (Total Recall, 1990).avi" -ss 01:07:29 -to 01:08:05 fight.avi Output: Input #0, avi, from '╨Т╤Б╨┐╨╛╨╝╨╜╨╕╤В╤М ╨▓╤Б╨╡ (...
1
vote
2answers
799 views

ffmpeg: mute first 2 seconds in all audio streams

Looking to edit a blip out of the beginning of a video/audio file: How can I use ffmpeg to only edit the first two seconds of the clip so that there's no longer that blip in the audio? How do I ...
0
votes
1answer
77 views

FFMpeg concat demuxer corrupted output (freezed video on some concatenated parts)

I have big videos with different types of properties and trying to collect some part of these videos by ffmpeg. I use this command to cut specific parts: scale video >> scale png >> pad ...
0
votes
1answer
71 views
0
votes
1answer
123 views

Add transparent background to ffmpeg with text over it

How to correctly add expression to transparent background like on this question ffmpeg drawtext filter - create transparent background with text for my case (where there are 3 lines in bottom right ...
0
votes
1answer
51 views

Reducing the frame rate : the smooth video Issue

This is my smooth video. Video details: Frame rate=60 FPS Video codec: h264 Not have any audio stream I want to convert it to a PAL video, But I can't get smooth video. How to convert a high ...
0
votes
1answer
33 views

Extracting individual video fields

I need to extract all video fields of an interlaced file as individual images. Is it possible to do this (using ffmpeg or other tools for Windows)?
0
votes
2answers
138 views

ffmpeg - burning in subtitles with non-square pixels

I've got a 16:9 standard-def movie into which I need to burn some subtitles. I'm using ffmpeg -y -i input.mov -vf ass="./captions.ass" output.mov and in the subtitle.ass file I've tried PlayResX: ...
0
votes
1answer
532 views

ffmpeg drawtext clipping to a bounding box

I'm trying to create a transparent box with some text in it and then overlay that onto a (bigger) existing video. I know I can do the text directly over the video, but I need the text bounded inside ...