Sunshine icon indicating copy to clipboard operation
Sunshine copied to clipboard

NVIDIA NVENC new preset

Open Isalight opened this issue 3 years ago • 5 comments

Describe the Bug

Nvidia has made new presets for nvenс. In the next driver / video codec sdk updates old presets will be removed after Q1'2023.

https://developer.nvidia.com/blog/introducing-video-codec-sdk-10-presets/ https://docs.nvidia.com/video-technologies/video-codec-sdk/deprecation-notices/index.html

Expected Behavior

Replace old preset to:

  • p1 (perfomance)
  • p2
  • p3
  • p4 (default)
  • p5
  • p6
  • p7 (quality)

Delete old rate control:

  • cbr_ld_hq
  • cbr_hq
  • vbr_hq

Add tuning info and multi pass settings.

https://docs.nvidia.com/video-technologies/video-codec-sdk/nvenc-preset-migration-guide/index.html

Additional Context

Performance comparison of all presets https://github.com/Xaymar/obs-StreamFX/wiki/Encoder-FFmpeg-NVENC#performance-measurements

OBS implementation https://github.com/obsproject/obs-studio/commit/d7c7180a8c55498a484d6e3b132f23e69ab3d553

I compared the old presets with the new ones according to the migration guide. Used ffmpeg-2022-06-16-git-5242ede48d to encode "Spider-Man Into the Spider-Verse" trailer with settings

  • -c:v hevc_nvenc -preset llhq -rc cbr -b:v 20M (identical to current default settings)
  • -c:v hevc_nvenc -preset p4 -tune ll -rc cbr -b:v 20M
  • -c:v hevc_nvenc -preset p4 -tune ull -rc cbr -b:v 20M

The new preset showed better encode time with slightly lower quality.

And try multi pass encode according to recommended NVENC settings -multipass qres. https://docs.nvidia.com/video-technologies/video-codec-sdk/nvenc-video-encoder-api-prog-guide/index.html#recommended-nvenc-settings

nvenc

Sunshine Host Operating System and Version

Windows 10

Architecture

64 bit

Sunshine Version

0.12.0

GPU Type

Nvidia

GPU Model

GeForce RTX 3060 Ti

GPU Driver/Mesa Version

512.15

Capture Method (Linux Only)

No response

Isalight avatar Jun 17 '22 17:06 Isalight

https://github.com/SunshineStream/Sunshine/discussions/123#discussioncomment-2781231

ReenigneArcher avatar Jun 17 '22 17:06 ReenigneArcher

This issue is stale because it has been open for 90 days with no activity. Comment or remove the stale label, otherwise this will be closed in 5 days.

github-actions[bot] avatar Sep 16 '22 00:09 github-actions[bot]

This issue was closed because it has been stalled for 10 days with no activity.

github-actions[bot] avatar Sep 27 '22 01:09 github-actions[bot]

Oh thanks, that's definitely what I was looking for.

sandr1x avatar Nov 10 '22 02:11 sandr1x

This issue has been fixed and will be available in the next release.

LizardByte-bot avatar Dec 28 '22 03:12 LizardByte-bot