Questions tagged [ffmpeg]

Media tool with support for multiple codecs, filters, and containers. Include your actual command and the complete console output when asking questions involving FFmpeg tools. An easy way to do this is by adding `-report` to your command and pasting the contents of the logfile generated. For help with CLI use only of ff* binaries - ffmpeg, ffprobe, ffplay. For help with API usage, post on Stack Overflow.

Filter by
Sorted by
Tagged with
2 votes
0 answers
53 views

Retrieving per-frame time difference from ffmpeg/ffprobe

I am attempting to reconstruct velocity information of an object from iPhone videos, and so I am interested in determining the time difference between frames. From what I understand, iPhone (HEVC ...
0 votes
0 answers
37 views

nvenc scale_npp causes FFmpeg to fail to launch HLS nginx

After updating my graphics card from a 680 to a 1650, I am now able to encode multiple bitrates of my HLS stream using NVENC. However, I am stumped with the following issue, if I attempt to add the ...
0 votes
1 answer
58 views

FFmpeg audio normalization from multi-channel audio to stereo to fix the quiet dialogues

When playing 5.1 surround sound audio on stereo, the dialogues come out quiet low but the other sound effect comes out heavily loud. Fortunately, FFmpeg already has built-in filters to fix this issue ...
0 votes
0 answers
15 views

How do I batch stack one video with a set of another videos in ffmpeg?

I have several mp4 files I am trying to combine into new videos. What I want to do is this without typing out the command a billion times: ffmpeg -i file1.mp4 -i file2.mp4 -filter_complex vstack ...
0 votes
0 answers
78 views

Decoding aac to PCM in ffmpeg introduces noise in the raw PCM audio

I have a .mp4 file generated with ffmpeg as follows. ffmpeg -y -i video_extended.mp4 -itsoffset 00:00:04.00 -i output5-1.wav -map 0:0 -map 1:0 -c:v copy -c:a aac -ac 6 -ar 48000 -b:a 128k -async 1 ...
  • 101
0 votes
0 answers
12 views

Xfade not getting applied on the last clip when merging 10 clips

I am facing issue while applying xfade on multiple videos using complex filter graphs, fade is always getting missed at the last clip of the sequence, is this a limitation of ffmpeg, Can some please ...
-1 votes
2 answers
50 views

Why is ffmpeg_g slightly bigger than ffmpeg with --disable-debug?

When I compiled FFmpeg with --disable-debug, ffmpeg_g (22.2 MiB) was slightly bigger than ffmpeg (20.9 MiB), Why?
0 votes
0 answers
26 views

FFMPEG How to copy stream but limit upload bitrate

I'm using the following command to copy a video stream and push it to an rtmp URL: ffmpeg -re -i "http://example.com/index.m3u8" -g 50 -c copy -bf 0 -b:v 2M -maxrate 2M -bufsize 1M -f flv &...
0 votes
0 answers
16 views

Subtitles - Muxing but removing info from title

So I've got some files being muxed into an mkv file and I add a subtitle to it. I want to remove the [gre] (ass) part from the following subtitle info (title): Example Here Code: ffmpeg.exe -i video....
  • 1
1 vote
0 answers
167 views

FFMpeg Invalid PNG signature when overlay

I am trying to use ffmpeg in order to generate a video with an audio provided, a plain background (jpg), a logo (png, transparent background) and a video overlay (black background) between my ...
0 votes
1 answer
45 views

ffprobe/ffmpeg subtitle index mismatch

So this is driving me insane. I have a video file, input.mkv, with several subtitle streams. I want to hardcode one of these subtitle streams into a new file. I usually do this like so: inputfile=&...
1 vote
0 answers
150 views

How can I smooth/deblock a video file with FFMPEG?

I am not interested in upscaling my video file, but am instead interested in just encoding it to smooth out the pixelation of my files. My files are from a T2i DSLR and I'd just like to smooth out the ...
0 votes
0 answers
21 views

Create 1 mp3 file out of several mp3 files some with a different tempo, a pause between each mp3 files and a background music

I'm trying to create 1 mp3 file containing: mp3 file 1 (playing at tempo 0.7) a 1 second pause mp3 file 2 (playing at tempo 1) a 1 second pause mp3 file 3 (playing at tempo 0.8) create the mp3 file ...
0 votes
0 answers
45 views

ffmpeg stream Attachment: ttf causes error

I tried to convert a mkv file to a mp4 file with h265 encoding. I want to keep all streams. I tried it with `ffmpeg -i INPUT.mkv -map 0 -c:v libx265 -c:a aac -c:s mov_text "compressed/OUTPUT.mp4&...
0 votes
0 answers
30 views

Video Format large screen wrong

we have problems with some videos beeing played in media-player. media-player reads the video size wrong. The videos are displayed too large, say for large screen like today. But the videos are for ...
0 votes
0 answers
15 views

Cutting out static frames with FFmpeg

I need to deal with video that has missing frames. It results in a video that jumps out this part when playing (though frames are shown as duplicates) Is there a way I do with FFmpeg either cutting ...
  • 1
0 votes
0 answers
88 views

mp4 encoded with ffmpeg not displaying on chrome

I am using the command ffmpeg -i input.mp4 -c:v libx265 -vtag hvc1 -c:a copy output.mp4 in order to compress my mp4 files. This is the output: ffmpeg version 5.1.2 Copyright (c) 2000-2022 the FFmpeg ...
0 votes
1 answer
107 views

Append one MP4 file to other MP4 file using FFMPEG

I would like to concatenate TWO MP4 files without re-encoding. Both have same characteristics. As suggested on some forums, I use a following command: "C:\Program Files\ffmpeg\bin\ffmpeg.exe"...
  • 770
0 votes
1 answer
62 views

Frame export for VFR video failing with -vsync passthrough option

I have a VFR video for which I am trying to extract all frames to .jpg's. Applying ffprobe -i Video_Stream_0.mp4 -print_format json -loglevel fatal -show_streams -count_frames -select_streams v shows ...
  • 3
0 votes
1 answer
48 views

remove audio from all mkv files in a directory with ffmpeg

I have a directory full of videos in mkv format, and I want to remove the audio from all of them. I'm using ffmpeg I tried this command: for f in (*.mkv); do ffmpeg -i "$f" -an -c:v copy &...
0 votes
0 answers
46 views

How to bulk downgrade videos that are higher than 2,000kpbs to be a max of 2,000kpbs with FFmpeg?

I have a problem and that is I want to run Plex on my Raspberry Pi. It works pretty well. Some of the videos though are too large to stream with the CPU constraints. So in that case I need to make ...
0 votes
0 answers
44 views

Why am I getting an error when attempting to convert an MP4 video to RealMedia video with FFmpeg?

FFmpeg failed to transcode test1.mp4. Below are the reported errors. I want to convert my video to RealMedia, so what is good preset for my goal? [rm @ 0x55795eac0340] Muxing packets larger than 64 kB ...
  • 1
0 votes
1 answer
34 views

How to combine these two ffmpeg commands so that no intermediate file gets generated?

I need to concat two files with this command. ffmpeg -ss 00:04 -to 1:15:28 -i 1_out.mp4 -ss 0:42 -to 10:28 -i 2.mp4 -lavfi concat=n=2:a=1 result.mp4 However, I need to scale 1.mp4 before the ...
0 votes
1 answer
189 views

ffmpeg webm (codec vp9) to mp4 not working on all browsers

I'm recording a video from chrome browser in webm format and on the backend side I want to convert it into mp4 so it can be played back on all devices. The video has this sample name: test.webm;...
0 votes
0 answers
36 views

Transcoding multichannel audio to AAC failing

I’m having issues transcoding multichannel audio to AAC. Depending on the source material I either define a speaker layout/channel order and write that into the FMT chunk of an RF64 .wav (e.g. L R C) ...
  • 21
1 vote
1 answer
65 views

Mux multiple mp4-m4a files without ask to overwrite

I try to mux multiple mp4 files (without audio) with m4a files located in same folder Generic command is for %%a in ("*.mp4") do ffmpeg -i "%%~na.mp4" -i "%%~na.m4a" -c ...
0 votes
0 answers
56 views

Reorder scrambled H.264 frames with ffmpeg

I have a video file that contains an H.264 stream inside an MPEGTS 'container'. I want to extract the video stream without re-encoding it and place it inside a proper container, like MP4 or MKV. The ...
  • 115
0 votes
0 answers
57 views

Join multiple .mpg files using ffmpeg while skipping those with errors

I have multiple mpg files from a broken video file recovered from an old CD. I wanted to join all of them into a single video file. I have gone through How can I join multiple .mpg movie files? and I'...
1 vote
3 answers
49 views

How can i remove multiple parts of audio in 1 command with Ffmpeg?

Im trying to cut multiple parts of audio with ffmpeg, i was able to find a working result (for video ) for a single filter : ffmpeg -i input.avi -vf "select='1-between(t,20,25)', setpts=N/...
  • 11
0 votes
1 answer
42 views

How to broadcast video to Vimeo stably by using ffmpeg?

I'm trying to broadcast video to Vimeo by using ffmpeg to broadcast from headless linux. Seemingly I can broadcast and video has no problem, but when I see analyzer, receiving bitrate is not stable. ...
  • 1
1 vote
0 answers
39 views

Remove Metadata Tags from Videostream with ffmpeg

I am trying to remove the language metadata tag from the video stream with ffmpeg and leave everything else untouched. My code is: ffmpeg -i "input" -metadata:s:v:0 language= -c:v copy -c:a ...
  • 35
0 votes
0 answers
36 views

How do I split a video into n number of parts when not knowing the video length using ffmpeg?

I want to split a large .mp4 video(length is unknown) into multiple small .mp4 videos. But I want to do it by dividing the length of the video by the number of parts required e.g: largevideo.mp4 = 4 ...
0 votes
0 answers
33 views

Play two audio files at the same time on different devices

How can I use a single ffmpeg or ffplay command to play two audio files at the same time, but through different output devices? As is documented, this command plays a single audio through the output ...
0 votes
0 answers
121 views

yt-dlp playlist re-stream FFMPEG constantly dropping

yt-dlp "https://www.youtube.com/playlist?list=PL63F0C78739B09958" --exec "ffmpeg -i {} -vcodec libx264 -c:a aac -b:a 160k -crf 23 -preset fast -f flv rtmp://127.0.0.1:1935/live/mytv10&...
  • 1
1 vote
1 answer
63 views

Only convert codecs(preserve audio and subtitles)

I have a video file h265 mkv which has dual audio and multiple subtitles. I want to convert it to h264 since it doesn't require further transcoding on my jellyfin server. But I haven't been able to ...
  • 11
1 vote
1 answer
73 views

Audacity error importing .m4a file

Getting this error : I have ffmpeg already installed on my system and also environment part has been set. When searched on internet it was showing to install ffmpeg but I have ffmpeg installed on my ...
  • 404
0 votes
1 answer
24 views

Inconsistent overlay position because of different resolutions

I'm using this command ffmpeg -y -i input.mp4 -i logo.png -filter_complex \ "[1][0]scale2ref=w=iw/14:h=ow/mdar[logo][main];[main][logo]overlay=30:20" \ -c:v libx264 -c:a copy output.mp4 And ...
  • 13
0 votes
2 answers
65 views

What's the difference between ffmpeg-snapshot.tar.bz2 & ffmpeg-snapshot-git.tar.bz2 on ffmpeg.org

On ffmpeg.org when you go to “Download > Download Source Code” it gives you ffmpeg-snapshot.tar.bz2 But if you click on “Get the Sources”, git snapshot it gives you ffmpeg-snapshot-git.tar.bz2 on ...
1 vote
1 answer
43 views

Scaling a logo to be consistent between video sizes

I'm now using this command to scale a logo overlay ffmpeg -y -i vid.mp4 -i logo.png \ -filter_complex "[1:v]scale=in_w*.25:-2[logo];\ [0:v][logo]overlay=30:20" out.mp4 But, sometimes the ...
  • 13
1 vote
1 answer
56 views

How can I batch convert a directory of subfolders, maintaining similar filestructure for the output

Right now I am converting using the following in Command Prompt: FOR /F "tokens=*" %G IN ('dir /b /s *.mp4') DO (ffmpeg -i "%G" -c:v libvpx-vp9 -crf 30 -b:v 0 -b:a 128k "%~nG....
  • 11
0 votes
0 answers
93 views

Video output is slow and is using more frames than the original

So basically, im interpolating videos and then upscale them, flowframes to interpolate(RIFE Cuda), and to upscale real_esrgan, but im having problems with with ffmpeg, im using it to extract the ...
0 votes
0 answers
28 views

fixing not multiple of 4 with buffer dimension

So, I've made some .bat droplets to convert video files to HAP. It has been working nicely, but occasionally I get an error when I can't convert a file if it is not a multiple of 4. My workaround was ...
2 votes
0 answers
58 views

How can I use a widely-available cross-platform command line program to render a string containing emoji [closed]

I would like to use a widely-available command line program, the lighter-weight the better, to render a string containing emoji into a raster image. The rules are: must work on a minimum of OS X and ...
  • 121
0 votes
0 answers
32 views

How to fix Windows Media Player not selecting correct audio track when playing an MP4 file?

Windows Media Player does not play back the correct audio track when one is selected from the Audio menu. This is for MP4 files with multiple audio tracks (around 32-64). VLC does the correct thing in ...
0 votes
0 answers
30 views

FFmpeg merge two audios by synchronizing from the end

I should merge two audios of different duration from the end. Expected result: 1st Audio <----------------------------------------------------> 2nd Audio <----------...
  • 1
0 votes
1 answer
184 views

Using FFmpeg to make a movie from PNG files: .WEBM with video filter blending error: Output file is empty

Commands: ffmpeg -framerate 0.5 -i %03d.png ffmpeg-framerate0.5.webm and ffmpeg -r 0.5 -i %03d.png ffmpeg-r0.5.webm create a working .webm videos, just as expected. But ffmpeg -framerate 0.5 -i %03d....
  • 1
0 votes
1 answer
54 views

Ffmpeg scale2ref aspect ratio preservation doesn't preserve the aspect ration exactly as desired

I'm trying to scale an image overlay on top of a video so that it fits within the video but preserves it's original aspect ratio. From googling around I came up with this: [img_src][video_src]...
  • 73
0 votes
0 answers
36 views

ffmpeg: Can the video scope filters be generated at higher resolutions/sizes?

I'm trying to overlay different video scopes (waveform, verctorscope, histogram) on a 4K source in real-time, but they look very small on the resulting frame. I can scale them up but they look blurry, ...
  • 101
0 votes
0 answers
39 views

ffmpeg segment command adds black frame

I'm going through a problem that I cannot solve with the ffmpeg segment command. I need to split a video in multiple chunks, and I am trying the following: ffmpeg -i input.mov -c copy -an -map 0 -...
0 votes
0 answers
36 views

FFmpeg batch: overlay two videos, keep background video's audio throughout and mix both audio streams only during overlay

I'm trying to figure out an FFmpeg batch command that overlays two videos. Background video is longer and its audio should be present thoughout. Overlay video comes in at 2 seconds into the bg video ...
  • 13