Add support for VIDEO_CS_SRGB.
Use SMPTE 170M for 601 instead of undef/BT470BG. This is the
American/Chromium way of handling 601.
Add color metadata to the container file as well via ffmpeg-mux.
If we fallback to ffmpeg NVENC, the error from new NVENC might still be
present in the encoder structure. Given that this provides a lot more
actionable information to the user, let's use it if possible.
Code submissions have continually suffered from formatting
inconsistencies that constantly have to be addressed. Using
clang-format simplifies this by making code formatting more consistent,
and allows automation of the code formatting so that maintainers can
focus more on the code itself instead of code formatting.
According to nvidia's documentation using b-frames as reference results in
a slight quality improvement with no/negligible performance impact and is
recommended to be enabled by default when using multiple b-frames.
Adds VBR rate control mode, adds a lookahead option, adds psycho visual
tuning option, removes level property (now always set to 'auto'),
removes "2pass" option (replaced by new "Max Quality" preset which uses
2pass by default), modifies a few defaults, and updates their locale
text.
When this was being fixed up, the incorrect function name was used --
however it still compiled because the author was using the newer FFmpeg
version at the time.
The "default" preset is not an actual default, but something Nvidia
decided to just call that way. It yields the worst quality per bitrate
out of all the presets, for no actual benefits. The actual FFmpeg
default is the hq one, which yields the best quality, especially when
twopass mode is enabled.
I can't think of a way to keep the "default" preset in a non-confusing
way, and as it gives no known benefits, might as well just remove it
entirely.
(Jim edit: Also made it so that if the settings have it set to
"default", it automatically treats it as "hq")
Closesjp9000/obs-studio#865
The encoder name was changed from "nvenc_h264" to "h264_nvenc", and will
throw a warning in the log file if you use the former, so try the latter
first, then the former.
Instead of using an option that turns CBR on/off, adds rate control
methods: VBR, CBR, CQP, Lossless.
This moves lossless from being a preset to being a rate control method.
The if statement erroneously ended with a ';', which means that the code
is always executed, but there's no reason to even have these if checks
in the first place as the functions themselves return safely with null
pointers.