Skip to main content

New answers tagged

0 votes

How to force ffmpeg download live m3u8 from the first available segment?

No that does not work. Sorry I meant these commands don't work Ffmpeg does not recognise -live_start_index Or -99999 As I how are you supposed to do it? Thank you
James's user avatar
  • 1
0 votes

How to force ffmpeg download live m3u8 from the first available segment?

No that does not work. Ffmpeg does not recognise -live_start_ibdex Or -99999 As I how are you supposed to do it? Thank you
James's user avatar
  • 1
0 votes

How to update this script to generate HLS video with different resolution streams?

why is -hls_list_size 0 ?? change that to 5 refer the following thread https://stackoverflow.com/questions/71913543/how-to-generate-multiple-resolutions-hls-using-ffmpeg-for-live-streaming
Abhishek's user avatar
0 votes

Convert video from 9:16 to 1:1 with blurred box using ffmpeg?

ffmpeg -y -i scene_2.mp4 -filter_complex "[0:v]scale=405:720:force_original_aspect_ratio=increase,crop=405:720,gblur=sigma=20[bg]; [0:v]scale=406:229[ov]; [bg][ov]overlay=(main_w-overlay_w)/2:(...
Ravi Pratap Rai's user avatar
0 votes

Use ffmpeg to create a video from a few images

how use with subdirectory? Command: ffmpeg -framerate 1/X -i subdirectory/img%d.png -r 25 -pix_fmt yuv420p out.mp4 Result: Error opening input file subdirectory/img%d.png.
Xitano's user avatar
  • 1
1 vote
Accepted

What are brightness, gamma, and lut filters doing to my video? What's the difference, which should I prefer?

Here's what all these settings do, typically. Some pieces of software define or apply them differently, but this should give a general idea. Brightness simply changes the brightness value of each ...
Cam's user avatar
  • 221
0 votes

How to properly specify font file for ffmpeg as it's always defaulting to Arial?

try this : ffmpeg.exe -i "filename" -filter_complex "subtitles=filename.ass:fontsdir=./fonts:force_style='FontName=Arial Rounded MT Bold,PrimaryColour=&H0000FFFF,SecondaryColour=&...
Samile's user avatar
  • 1
0 votes

Pink and green color on overlay logo

The video format should be changed to rgb by adding format=gbrp before blending, i.e. the filter_complex command should read: [0:v]format=gbrp[a];[a][1:v]overlay=x=main_w-overlay_w-(main_w*0.011):y=...
SkepticaLee's user avatar
0 votes

How Do I Batch Convert to Ogg Theora with FFmpeg6?

Use GNU Parallel for encoding more than one at a time, since libtheora is not multithreaded. parallel ffmpeg -v 24 -i {} -c:v libtheora -q:v 7 -vf "scale=-2:720:flags=lanczos+accurate_rnd" -...
veppy's user avatar
  • 81
0 votes

How to calculate the CPU resources required to use ffmpeg to transcode a video stream

Pass -benchmark to ffmpeg with some samples. You'll have to test it on another system to estimate what will be required, because memory and CPU usage also depends on the version of ffmpeg and its ...
veppy's user avatar
  • 81
1 vote

Best ffmpeg compression settings for fast seeking of long 4 hour clip

I'd recommend considering these workarounds in this order, until it seeks fast enough: Make sure hardware video decoding is turned on Switch to a faster video player Decrease the GOP to one second ...
veppy's user avatar
  • 81
0 votes
Accepted

How to change resolution without compromising video quality using ffmpeg?

Is there a big difference between encoding the video and audio separately in the original video file and encoding the original video file as is? If you're only downscaling the video, then you can ...
veppy's user avatar
  • 81
1 vote

verify lossless in H.264

Just do this: ffmpeg -i $input -i $output -lavfi ssim -f null - This will compare the two videos using SSIM. If it's lossless then you will see: SSIM Y:1.000000 (inf) U:1.000000 (inf) V:1.000000 (inf)...
veppy's user avatar
  • 81
1 vote

Why does setting the bitrate with ffmpeg has no affect on the filesize?

The default encoder for mpegts is mpeg2video (producing a H.262 bitstream). This is an ancient encoder for an ancient codec and it is not capable of supporting a 1k or 0.5k video. Even modern codecs ...
veppy's user avatar
  • 81
0 votes

ffmpeg mov_text subtitle too small when converting mkv to mp4

I was having a similar issue and realised it was because the subtitles contained style information that VLC was only rendering in the output file, not the input file. Have you checked if the SSA ...
mxrmo's user avatar
  • 1
1 vote

How do I get better sound quality when screencasting with ffmpeg without having to increase -r?

For x11grab you should be using -framerate and not -r. Here is what you should use: ffmpeg -f x11grab -framerate 25 -s ${dimensions} -i ${DISPLAY} -f alsa -ac 2 -i default -c:v libx264rgb -crf 0 -...
veppy's user avatar
  • 81
1 vote
Accepted

Impact of reencoding an HEVC file: How much loss if I do it in two steps, vs. going directly to a lower bitrate?

Is there a benefit to go back to the original file and reencode it at 40Mb/sec bitrate, vs. using the already reduced 50Mb/sec file and reencoding that one at 40Mb/sec? Every single time you reencode ...
veppy's user avatar
  • 81
0 votes

ffmpeg input -ss accuracy

tnx gyan, more or less understood. I'll have to try. problem started with recent versions of ffmpeg (5.1 & above); up to version 4.3 to extract a frame at exact timestamp, without waiting log time ...
templeton's user avatar
1 vote

ffmpeg input -ss accuracy

MPEG-TS don't have a global keyframe index ,so even input -ss will seek to the next KF after the ss timestamp. Add -copyts -start_at_zero and seek to a few seconds earlier. Then add a trim filter with ...
Gyan's user avatar
  • 33.3k
0 votes

How to prevent FFmpeg from dropping metadata?

ffmpeg does not correctly preserve Keys tags in movie metadata. The problem is that the Keys tags are embedded in UserData atom which Apple's apps do not display: ffmpeg -i input.mp4 -c copy -movflags ...
wywh's user avatar
  • 61
2 votes

Seeking Tool(s) to Restack Frames from an MP4 Video of a Total Solar Eclipse to Keep the Sun Always Centered

Start by converting your images into a video. Based on your question, I'm assuming you either have done this or know how to do it. You can then take your file into After Effects, and use a stabilizer ...
Cam's user avatar
  • 221
1 vote

Add an image overlay in front of video using ffmpeg

If you wanna resize the image. ffmpeg -i input.mp4 -i image.png -filter_complex "[1:v]scale=480:854[overlay]; [0:v][overlay]overlay=0:0:enable='between(t,0,20)'" -pix_fmt yuv420p -c:a copy ...
requizm's user avatar
  • 11

Top 50 recent answers are included