31
votes
Accepted
Can I set the start number for image sequence output?
The image sequence muxer has a start number option, so
ffmpeg -i video.webm -start_number 98 image-%03d.png
12
votes
How to downsample 4k to 1080p using ffmpeg while maintaining the quality?
Convert 4k to 1080 (no change in codec)
ffmpeg -i input4kvid.mp4 -vf scale=1920:1080 -c:a copy output1080vid.mp4
Convert h.264 to h.265 (no change in resolution)
ffmpeg -i input.mp4 -c:v libx265 -...
12
votes
Accepted
Big difference in the video file size after the conversion (.mov to .mp4)
Let me explain you from scratch.
MOV, MP4, AVI, MKV etc all these are just containers, It is just kind of wrapper which contains audio, video, text, metadata file together as one file. It does not ...
9
votes
Accepted
Apply custom lut via ffmpeg?
You may want to use FFMPEG's lut3d filter. It requires you to provide a look-up table (a *.cube file). For example, if you have an ARRI camera you can generate these files using ARRI Color Tool or ...
8
votes
Accepted
Does transcoding always mean quality loss?
Generally, H.264 and H.265 (as well as others like VP9) are lossy codecs, at least in their default settings with most encoders. This means that whenever you re-encode from one to another (or even in ...
6
votes
Accepted
FFMPEG stop converting from TrueHD to PCM
The WAV header is typically 32-bits. Your output will need 64 bits.
ffmpeg -i source.thd -c:a pcm_s24le -ar 48000 -rf64 auto output.wav
6
votes
Accepted
Convert video with ffmpeg to have the same quality
The differences between your "works" and "doesn't work" examples are:
resolution
framerate
Codec Tag
Codec Level
and you can set these using ffmpeg:
ffmpeg.exe -i /temp/input.mp4 -c:v mpeg4 -level ...
6
votes
Accepted
Lossless convert 3gp video to mp4 using ffmpeg
If the codecs of your input file are already h264 and aac for video and audio, respectively, you can just copy without decoding and encoding again.
ffmpeg -i input.3gp -c:v copy -c:a copy output.mp4
...
5
votes
Accepted
Loss of quality while adding subtitle via FFmpeg
As you are hardcoding subtitles, the video (with the subtitles added) will be re-encoded.
You can use the CRF rate control method to modulate the quality of the output.
So, start with
ffmpeg -i ...
5
votes
Accepted
Problem converting TS to MP4 container with ffmpeg
Update: The VLC TS is malformed.
First run
ffmpeg -i vlc-output.ts -c copy ffmpeg-output.ts
and then
ffmpeg -i ffmpeg-output.ts -c copy working.mp4
The main thing that looks off is the timebase ...
5
votes
Easily convert & archive a bunch of low res Video CD DAT files MPEG 1/2 to newer better format such as MKV or others?
Using ffmpeg, a free command-line tool, you can convert these DATs to MP4 (or MKV):
ffmpeg -i input.dat -c:v libx264 -crf 20 -c:a aac -b:a 128k -movflags +faststart output.mp4
Your VLC output doesn'...
4
votes
How can I efficiently convert MOV / MPEG-4 files for long term storage?
Although @stib's advice is sound, I disagree with "to get an appreciable size reduction you would have to throw away a lot of quality". Cameras have to compress on-the-fly, so they use constrained ...
4
votes
Accepted
what graphics card features effect NVIDIA NVENC hardware encoding speed?
There are two main features in NVIDIA NVENC encoding:
Video memory if you need to transcode many streams.
NVENC SIP - than better this SIP than better encoding performance
is. It depends on GPU. You ...
4
votes
Accepted
mplayer/ffmpeg How to set caca filter's output size
Found. Caca library is driven mostly by environment variables rather than filter params.
export CACA_GEOMETRY=200x78
mplayer -vo caca $INPUT
4
votes
Accepted
ffmpeg to convert and merge 3 videos to a single widescreen video
Quality-wise, it's better to use the original MOVs, but if the MP4-based stacking looks ok, that's the final arbiter.
ffmpeg -i left.mov -i centre.mov -i right.mov
-filter_complex "[0:v:0][1:v:0][2:...
3
votes
Accepted
Video metadata: What is "Video delay" used for?
Streaming formats maintain timestamps for each frame, whether audio or video, which govern when the player ought to present them. Those non-zero big start times usually occur when a snippet is cut out ...
3
votes
Accepted
Converting a Video from 1600*1200 to 1920*1080
Using ffmpeg,
ffmpeg -i input.mp4 -vf "scale=1920:1080:flags=lanczos,setsar=1" output.mp4
This will stretch the video to 1920x1080.
ffmpeg -i input.mp4 -vf "scale=-1:1080:flags=lanczos,setsar=1,pad=...
3
votes
Accepted
Video format can't be played or converted
Use this ffmpeg* command:
ffmpeg -i "20151105-175532.dad" -c:v copy "20151105-175532.mp4"
*get 32-bit static build.
3
votes
Accepted
Why does VLC player convert a 4-minute mp4 to a 4-hour webm?
Yes, it seems to be a problem of generated timecode. See https://trac.videolan.org/vlc/ticket/12713#no1
Switch to ffmpeg (with a GUI like Avanti) to avoid this issue. My answer to an earlier webm ...
3
votes
Accepted
convert horizontal side by side to vertically stacked 3D video
Just integrate all filtering into one command:
ffmpeg -i input.mp4 \
-filter_complex "[0:v]crop=in_w/2:in_h:0:0 [top]; \
[0:v]crop=in_w/2:in_h:in_w/2:0[bottom]; \
[top][bottom]vstack[outv]" \
-map "[...
3
votes
Accepted
Convert resolution 4096x2304 to 3840x2160 keeping the quality the same
Judge based on the quality rather than the bitrate value. Use CRF mode encoding and if the quality isn't what you can accept, decrease the CRF value.
ffmpeg -i "%%a" -s 3840x2610 -c:v libx264 -crf 18 ...
3
votes
Accepted
How to double video frames without any duplicate frames
Use
ffmpeg -i in.avi -r 50 -filter:v "setpts=0.5*PTS" out.avi
or
ffmpeg -i in.avi -r 50 -filter:v "setpts=N/50/TB" out.avi
If you want to interpolate new frames, use
ffmpeg -i in.avi -r 50 -...
3
votes
Audio issue on concatenation of TS segments
Don't use the concat demuxer. Create a single ts file by concatenating the ts segments as a first step. Then run it through ffmpeg.
i.e.
cat 1.ts 2.ts >all.ts
ffmpeg -i all.ts -c copy all.mp4
3
votes
Accepted
Convert variable framerate ~60 FPS to constant 60 FPS losslessly
To start with: your version of Handbrake is old. Version 1.0.3 came out very recently, it's got some improvements over that older version.
Second, CQ0 is not actually "lossless." It's aiming for "...
3
votes
Accepted
Do I have any sort of loss converting an M4V file to MKV?
Your command
ffmpeg -i "path/to/file.m4v" -c:v copy -c:a copy "path/to/file.mkv"
does do a lossless copy since no recompression occurs.
You have to note all warning or error messages during the ...
3
votes
Accepted
Transcode 5.1 audio in ffmpeg leads to incorrect audio mapping in output
FFmpeg assumes that the input's 5.1 channel mapping is the same as the one it uses. To correct that, use the channelmap filter to remap, add:
-af "channelmap=4|0|1|2|3|5:5.1"
(I based it off the ...
3
votes
How to convert a 720° ".ts" video recorded with an AllieCam360?
FFmpeg can see both views as separate video streams.
You can remux the file to MP4 simply by using
ffmpeg -i input.ts -c copy -map 0 output.mp4
Hopefully, your video editor can work with distinct ...
3
votes
Video conversion
If you're up for using the command line, the best tool hands-down is ffmpeg. It can convert pretty much any video format out there into pretty much any other video format, it's free, open source, and ...
3
votes
Accepted
Reverting Loss from .MOV (MPEG-4 Compression)
No, there is no way to recover information lost during any encoding steps - they are discarded forever. The only way to avoid this is to use lossless encoding.
That said, there are various algorithms ...
2
votes
How to digitise old NTSC home videos for highest quality (with PAL player)?
The 2020 and beyond answer:
for whatever reason, the "SCART2HDMI" adapters floating around on eBay and Amazon, include electronics that used to be included in professional VCRs and TV studio ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
conversion × 206ffmpeg × 83
video × 70
mp4 × 25
audio × 16
file-formats × 16
encoding × 12
transcoding × 12
compression × 10
framerate × 9
mkv × 9
premiere × 8
video-quality × 8
software-recommendation × 8
video-editor × 7
codec × 7
h.264 × 7
subtitles × 7
editing × 6
windows × 5
quicktime × 5
mpeg × 5
final-cut-pro-x × 4
linux × 4
mac × 4