All Questions
Tagged with ffmpeg command-line
289
questions
-2
votes
1
answer
61
views
FFmpeg MP4 command not working as expected [closed]
I’ve tried to use FFmpeg to prepare a video for YouTube, based on the YouTube recommended upload encoding settings but can’t make it work.
Does anyone know the exact encoding FFmpeg command based on ...
1
vote
1
answer
68
views
FFmpeg: ffv1 -context parameter
What forces ffv1 to encode in intra-frame mode -context 0 or -g 1 or both?
It says here (in Compression details) that to force intra-frame encoding I should use -context 0 (as far as I understand).
...
1
vote
1
answer
109
views
FFmpeg -ss option and keyframes
I would like to clarify that I understand how to use -ss, -t, -to, stream copy, and the difference between stream copying and reencoding/transcoding.
What I don't understand, is how the seeking/...
1
vote
1
answer
103
views
Ffmpeg image parameter for YouTube
Is there any image png command equivalent to parameter below?
ffmpeg -loop 1 -framerate 2 -i input.png -i audio.m4a -c:v libx264 -preset medium -tune stillimage -crf 18 -c:a copy -shortest -pix_fmt ...
0
votes
1
answer
63
views
How do you create an ffmpeg lossless image without re-encoding?
I'm using the command below but not sure if it’s really lossless and without re-encoding? Is there specific command to create lossless image and without re-encoding? I'm new to this.
ffmpeg -lavfi &...
2
votes
1
answer
161
views
What a correct playlist.m3u8 should contain, or should look like?
24/06/2024: [Presentation of the problem]
I had dowloaded some videos from the Internet, few years ago.
I obtained many files:
a series of files in .ts
a single file playlist.m3u8
In my example:
A ...
0
votes
1
answer
80
views
How to solve a final pb when merging a series of .ts file with concat command of FFmpeg?
I had dowloaded some videos from the Internet, feaw years ago…
I obtained many files: a series of files in .ts
In my example: a series of 306 files named from segment1_4_av.ts to segment306_4_av.ts
A ...
1
vote
1
answer
52
views
why don't work old batch ffmpeg extraestereo command in new version?
I use this batch command for years in ffmpeg, but from update to the last version don't work and don't see in documentation whats the problem.
ffmpeg -i C:\Pelis\video.mkv -vcodec copy -map 0:a -map 0:...
1
vote
1
answer
92
views
How to use ffmpeg to convert a flac file to alac and preserving all metadatas?
I use this loop to convert flac to alac :
for i in *.flac; do ffmpeg -i "$i" -y -vn -c:a alac "${i%.flac}".m4a; done
But some tags are not exported. I tried to use the -...
-2
votes
2
answers
119
views
How to run an .exe file in command line without adding PATH variable in Windows? [closed]
I've recently downloaded ffmpeg and I need to run it through command line. I'm not able to do that because I don't have admin rights. How do I work around that?
0
votes
0
answers
59
views
How to create1080p and 4k black png background text in center using ffmpeg?
I’m trying to create a png black background with text in center using ffmpeg I left an image example from Canva. Please someone help by giving command line/parameters example for 1080p and 4K?
1
vote
2
answers
177
views
FFMpeg: How to get the real return value in bash
I've always used ffmpeg via a cmd-script and I always could check the %ERRORLEVEL% which was always '0' on success or '!0' if an error occured.
I'm trying to recode my cmd-scripts in bash (using msys2 ...
0
votes
1
answer
37
views
How to use ffmpeg speedup video specific time range in one line ffmpeg cli
I try following splited cli, they work well
ffmpeg -i "$input_file" -filter_complex "[0:v]trim=start=0:end=10,setpts=PTS/10[v1];[0:a]atrim=start=0:end=10,asetpts=PTS/10[a1]" -map &...
0
votes
1
answer
217
views
How to Batch Apply Multiple Commands? FFmpeg
I have three commands that I've got to work individually for a set of videos, but cannot get them to apply together. I need to apply all three of these things to every video.
1) add audio, 2) speed up ...
2
votes
1
answer
716
views
How to extract the timestamp (PTS) from the specific frame?
My input is a ts file. And I'm trying to use FFmpeg to extract the timestamp (PTS) from the specific frame index. I have tried the following command ( I have replaced the [FRAME_INDEX] with 5), but it ...
0
votes
0
answers
119
views
FFMpeg removes the video stream unintentionally
I used the following ffmpeg command to downscale a video. But surprisingly the output did not have any video stream, just an audio-only output.
ffmpeg -y -i "input.mov" -c:v libx264 -vf ...
1
vote
1
answer
1k
views
How does FFMpeg read from a remote s3 url
I'm intrigued how does FFMpeg read a video file from a remote url (for example, an aws s3 presigned url).
Does it download the file in chunks and then process it chunk by chunk?
Or does it download ...
0
votes
0
answers
172
views
FFMpeg creates image from a timestamp but not from another timestamp
While trying to create an image from a video, the following command does not create any output and completes with the warning
Command with timestamp 7 sec:
ffmpeg -ss 00:00:7.0 -i "input.mp4"...
0
votes
0
answers
71
views
FFMpeg series thumbnails created less than expected
I have the following ffmpeg command to create a 576p video, and series thumbnails at an interval of every 2 seconds.
ffmpeg -hwaccel cuvid -hwaccel_output_format cuda -i input_video.mp4 \
-vf "...
0
votes
1
answer
399
views
Send info from ffmpeg to text file & then parsing into a new file
I am trying to scan a directory of .mkv files and output the volume information to out.txt and then parse out.txt for volume_max and send it to log.txt using
for %i in (*.mkv) do ffmpeg -i "%i&...
2
votes
2
answers
733
views
How can I setup ffmpeg to continuously produce 1 second videos from piped jpgs?
I am using ffmpeg on Ubuntu 22.04 to create 1 second mp4 videos from piped jpgs. The only issue that I have is that ffmpeg stops executing after the first set of jpgs is piped in. I need ffmpeg to ...
2
votes
1
answer
1k
views
ffmpeg nvenc throws an error after I modified an x264 command
I'm trying to convert this command to work on nvenc hvec video encoder to just make it faster and utilize my 3060:
ffmpeg -i video.mkv -i logo.png -filter_complex "[1]format=rgba,...
1
vote
0
answers
96
views
Going round in circles with ffmpeg concat and filter_complex
Since I've 'flipped' my classroom I'm trying to work out the ffmpeg command that will concat a set of m4a audio files with a set of matching static PNGs to create a pre-recorded talk.
I have no issues ...
1
vote
0
answers
793
views
Generate a video with an image every 5 seconds using ffmpeg
I want to create a video from command line with some images like those:
-rw-r--r-- 1 dt dt 3360622 Sep 4 23:57 IMG_0670.jpg
-rw-r--r-- 1 dt dt 2949398 Sep 4 23:57 IMG_0671.jpg
-rw-r--r-- 1 ...
1
vote
0
answers
935
views
FFMpeg autorotate video and image output
I have a video which I'm trying to downscale to a video output, and also create a thumbnail image at every 2 seconds using a single FFMpeg command(hardware accelerated). Following is the command:
...
0
votes
0
answers
720
views
FFMPEG command to create subtitles isn't using the right font
I'm trying to use python to run an ffmpeg command to add subtitles onto a video, using an srt file.
I tried the following:
ffmpeg -y -i output.mp4 -vf subtitles=testsrt.srt:force_style='Fontname=...
1
vote
0
answers
181
views
is there a way to change dynamic the water mark text color when using ffmpeg depending on the background color when recording a video file?
This command in the command prompt window is working fine and recording the entire screen:
ffmpeg -f gdigrab -framerate 24 -i desktop -preset ultrafast -pix_fmt yuv420p out.mp4
this command prompt ...
-1
votes
1
answer
768
views
Two video overlays another with FFMPEG
I'm a new user of FFmpeg, and I want to insert a logo on two videos (one video overlay another) with one command.
FFmpeg command (ok):
ffmpeg -stream_loop -1 -i background.mp4 -i input.mp4 -i logo....
1
vote
1
answer
220
views
Creating a .bat for screenshotting folders with ffmpeg
I was looking for a .bat script for ffmpeg and came across this thread on the forum here.
The code in question is
for %%F in (*.mp4) do (
If not Exist "%%~nF" MkDir "%%~nF"
ffmpeg -...
1
vote
1
answer
67
views
VIdeo overlays another incorrectly - background is over overlay
I'm a new user of FFmpeg, and I want to insert a logo on two videos (one video overlay another) with one command.
FFmpeg command (ok):
ffmpeg -stream_loop -1 -i background1080p.mp4 -i input1080p.mp4 ...
0
votes
1
answer
213
views
What is the difference between these 2 FFMPEG commands?
I am trying to take 5 static images named (1,2,3,4 and 5.jpg) and turn them in a 25 second video with each image being 5 seconds long.
ffmpeg -y -r 25 -loop 1 -t 5 -i 1.jpg -s 1080x1920 video1.mp4
...
0
votes
1
answer
438
views
Command to get only one audio track in output specified by language code with ffmpeg
Ffmpeg Command to get video with only English audio or only one language audio
I tried running ffmpeg -i input_video.ext -map 0:v -map 0:a:language=eng -c:v copy -c:a copy -map_metadata -1 -sn output....
3
votes
1
answer
9k
views
Using ffmpeg to download m3u8 video in two ways resulting in two vastly different sizes; Why?
I'm trying to download a m3u8 playlist (which contains 1.ts, 2.ts,..., xxx.ts) via ffmpeg. I'm doing it in two different ways:
Directly download:
ffmpeg -i "https://filelocation/chunked/myfile....
0
votes
1
answer
149
views
Is the cd command temporary?
Attempting to change my working directory...
In the command prompt, my input was:
cd F:
Command prompt returned:
F:\
Then another line appeared, reverting my working directory back to:
C:\Users\caden
...
-1
votes
1
answer
486
views
How can I burn in .ass file and a watermark to a video file using ffmpeg simultaneously?
I want to add subtitles and a watermark to a video using ffmpeg. For now, I'm using Handbrake to burn in the subtitles and later I execute an ffmpeg command to add a watermark from png file.
The ...
0
votes
1
answer
438
views
Where does completed file go by default when merging audio and video files together using ffmpeg?
So I merged an audio and video file together earlier using ffmpeg. I Did a full search on my hardrive for outPutFile.mp4 and it was nonexistant.
Now I'm running another, slightly altered command using ...
1
vote
0
answers
183
views
How to get exact timecode splitting using ffmpeg commands
I have a file called ffmpeg.cmd which has inpoints and outpoints.
file 'testA.webm'
inpoint 00:02:11.032
outpoint 00:02:36.900
file 'testA.webm'
inpoint 00:09:06.100
outpoint 00:09:43.799
If I run ...
0
votes
0
answers
326
views
Ffmpeg: how to get information about rawvideo encoder
For example, when i type:
ffmpeg -h encoder=ffv1
I have information about supported pixel formats:
Supported pixel formats: yuv420p yuva420p yuva422p yuv444p (...)
and settings:
ffv1 encoder ...
1
vote
0
answers
16
views
Inserting month in watermark is not using system locale
I need to insert the date in the video with the format %d %b %Y. My locale configuration is in spanish:
❯ locale
LANG=es_ES.UTF-8
LANGUAGE=es_ES.UTF-8
LC_CTYPE="es_ES.UTF-8"
LC_NUMERIC="...
1
vote
1
answer
2k
views
Is it possible on FFMPEG to send RTSP raw frames to pipe and write video segments by time to the disk?
I'm trying to receive RTSP frames to be processed by OpenCV, via ffmpeg using python. This is ok.
However I also need to write this video to disk one video each minute. This last part is the problem.
...
0
votes
0
answers
104
views
FFMPEG request is slow
I need to concatenate images to a video. Images contain black and white pixels, but I need to save quality of them as much as possible with saving space of disk. So, I don't need to use .mov.
And ...
1
vote
1
answer
316
views
FFmpeg command not producing desired video duration from image sequence
I have a set of 5 images and I want to use FFmpeg to create a video sequence from them. I am using the following command to achieve this:
ffmpeg -pattern_type glob -i '*_0[0-5].png' -r 25 -t 8 -c:v ...
0
votes
1
answer
297
views
Setting affinity for ffmpeg on command line not working as expected
I've read lots of articles on starting an application with a specific affinity
This works as expected and I see the the affinity is showing as expected:
start /affinity 3 notepad
However, when I try ...
0
votes
1
answer
183
views
Extracting Audio Snippets from mp3 file - unexpected results
I am trying to extract audio snippets using command line tools. I get consistent, unexpected results and I believe this is due to how the audio files were created/encoded.
Note: I realise there are ...
2
votes
1
answer
798
views
How to map ffmpeg multiple outputs to pipes
I'm working on a transcoder backend to a project that intends to serve static mpeg-dash manifests and files for a frontend player. And I'm trying to figure out how I can get multiple outputs into ...
1
vote
0
answers
448
views
ffmpeg input/output error when using mac system temp file path
I've got an ffmpeg command that is supposed to output a thumbnail for a given video at a resolution of [W]x720.
The input videos are uploaded and stored temporarily in the /var/folders directory on OS ...
0
votes
1
answer
511
views
ffmpeg convert images in a folder with no defined start number
I'm setting up a batch file to daily convert a folder of screen captures to video.
I can specify the filename of the screen caps, but I can't get it to reset each day, so say 2 might start at 03213. ...
0
votes
0
answers
507
views
I get "The code execution cannot proceed because avdevice-59.dll was not found." error when I run ffmpeg on my cmd
I'm trying to add FFmpeg to PATH. I have downloaded the windows executable ffmpeg files from the official website.
I have followed this article
to install ffmpeg into my computer and add to path. I ...
0
votes
1
answer
261
views
Combine 2 FFMPEG commands - 1. Create a video loop and 2. Add track to loop X times / Add track to loop duration of video loop
I have these 2 commands for FFMPEG, but can't work out how to use the output from the first command and link into the 2nd one, and use them as a single process. I have the following:
Loop video for ...
2
votes
2
answers
6k
views
Is there a way to extract subtitles from an MKV while maintaining the original format?
I am trying to extract (first, in case of many) subtitle track from mkv files (via CLI only, no GUIs) using ffmpeg or mkvextract.
But there is one downside to this: I have to write the output name ...