Newest 'x264' Questions - Stack Overflow
Les articles publiés sur le site
-
What is difference between using ffmpeg GOP setting or x264opt keyint combination ?
25 mars 2016, par scaryguyHere is a ffmpeg command:
ffmpeg -i input.mp4 -flags +global_header -c:v libx264 -vf scale="864x486",setsar=1:1,setdar=16:9 -profile:v main -level 31 -g 50 -keyint_min 50 -sc_threshold 0 -b:v 700k -pix_fmt yuv420p -c:a libfdk_aac -ar 44100 -ac 2 -b:a 128k output2.mp4
and here is the other one:
ffmpeg -i input.mp4 -flags +global_header -c:v libx264 -vf scale="864x486",setsar=1:1,setdar=16:9 -x264opts keyint=50:min-keyint=50:no-scenecut -profile:v main -level 31 -b:v 700k -pix_fmt yuv420p -c:a libfdk_aac -ar 44100 -ac 2 -b:a 128k output2.mp4
Are there any differences between using
-g 50 -keyint_min 50 -sc_threshold 0
and-x264opts keyint=50:min-keyint=50:no-scenecut
settings to gain constant keyframe interval? -
Difference between B-frame and b-frame when decoding x264
11 mars 2016, par Pieter VerschaffeltI'm trying to achieve the following frame-pattern when encoding with the x264-encoder:
IPBBPBBPBBPBBPBBI
So, basically I want every 16th frame to be an I-frame and between every 2 P-frames there have to be 2 B-frames. I use these parameters:
x264.exe -I 16 -i 16 --bframes 2 --b-adapt 0 --tune psnr --fps 25 --input-res 416x240
But this gives an output of
IPBbPBbPBbPBbPBbI
What is the difference between an uppercase B or a lowercase b in this context?
-
Why is x264 / x265 lossless encoding slower than lossy encoding
2 mars 2016, par RawBeanI am comparing x264 and x265 encoders, with
lossless
andmedium
presets. I am so surprised to see below performance results.| Format | Size (KB) | fps | |********************|*************|******| | YUV 420 | 9,182,363 | | | | | | | x265 (--lossless) | 442,890 | 1.8 | | x265 (--medium) | 12,243 | 2.8 | | | | | | x264 (--lossless) | 319,139 | 7.2 | | x264 (--medium) | 25,747 | 7.5 |
It raises two questions to me
Why lossless encoding processes less frames per seconds than lossy one? ( I supposed there should be less processing to do)
Why x265 lossless output is much bigger than x264 lossless output? Is this an implementation effect, or related to the HEVC standard?
-
PSNR for YUV files using matlab [duplicate]
29 février 2016, par apiprojThis question already has an answer here:
In my video streaming application I have two yuv files.One is original which is am streaming over the network after x264 encoding, another is reconstructed decoded yuv file in receiver side.
How to calculate PSNR value between two YUV files in MATLAB or ldecoder or using any other tool?
Thanks in advance.
-
x264 : ignore empty options in bash script
26 février 2016, par manesI do some video encoding using a script with x264. Most options follow the pattern
x264 --option0 $value0 --option1 $value1 -o output.file input.file
The script reads the values from a text file. The text file contains key-values like
crf=18.3
. Unfortunately, this does not work for mb-tree, as the option does not have a $value, it is set by default and can be turned off with--no-mbtree
.If
mbtree=no-mbtree
is set in the text file, everything works fine. But if I choose to encode with mbtree turned on, the--$variable-for-mb-tree-or-no-mb-tree
is still in place, but unset or empty and x264 throws an error.How can I tell bash/ x264 to ignore an unset or empty variable? I'd like to avoid an if…then…else and rather do it inline.