[FFmpeg-trac] #9165(undetermined:new): "Lossless encoding not supported" error occurs using NVIDIA Video Codec SDK 10.0
FFmpeg
trac at avcodec.org
Sun Mar 28 07:30:35 EEST 2021
#9165: "Lossless encoding not supported" error occurs using NVIDIA Video Codec SDK
10.0
-------------------------------------+-------------------------------------
Reporter: bombur33 | Type: defect
Status: new | Priority: normal
Component: | Version: git-
undetermined | master
Keywords: lossless | Blocked By:
nvenc h264 |
Blocking: | Reproduced by developer: 0
Analyzed by developer: 0 |
-------------------------------------+-------------------------------------
Summary of the bug:
When using h264 nvenc, a "Lossless encoding not supported" error occurs
using NVIDIA Video Codec SDK 10.0 on certain NVIDIA cards despite using
lossy settings. In this case, it's a GTX 960 (Maxwell), which doesn't
have lossless capability. When lossy settings are used, it shouldn't
matter that the card doesn't support lossless.
The problem seems to trace back from around line 361 of libavcodec/nvenc.c
that checks ctx->preset >= PRESET_LOSSLESS_DEFAULT. The new SDK 10
presets (p1-p7) seem to evaluate greater than PRESET_LOSSLESS_DEFAULT
despite the new -tune parameter not being set to lossless. In SDK 10, the
-tune parameter controls lossless rather than the preset. See the preset
migration guide:
https://docs.nvidia.com/video-technologies/video-codec-sdk/nvenc-preset-
migration-guide/#h264-preset-migration-table
How to reproduce:
{{{
% ffmpeg -hwaccel cuda -hwaccel_output_format cuda -i input -c:v
h264_nvenc -preset:v p1 -tune:v hq -rc:v vbr -c:a copy -y output.mp4
ffmpeg version
built on 2021-03-24
}}}
Patches should be submitted to the ffmpeg-devel mailing list and not this
bug tracker.
--
Ticket URL: <https://trac.ffmpeg.org/ticket/9165>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list