GPUs Practice Reviews

NVIDIA NvEnc vs. CPU encoding: Can the video encoder of the Turing cards be used for twitch streaming and keep up with a CPU? Analysis with Netflix VMAF

For some time now, a separate encoding chip, which Nvidia NvEnc has christened Nvidia NvEnc, has been used in many NVIDIA graphics cards. This is a real hardware solution that can convert videos quite efficiently. Currently the common codecs H.264 and H.265 as well as resolutions up to 8K are supported. The Turing generation now promises video quality superior to that of classic CPU encoding with less system load. Especially for livestreamers with high quality requirements, the only option so far was to use an expensive CPU with many cores of caliber of an Intel i9 or Ryzen 9 3900x.

Common 4- and 6-cores very quickly reach their performance limits in pure CPU encoding (x264), especially when a complex game is to run simultaneously. The NvEnc of the Turing generation is supported on the consumer-oriented GeForce graphics cards GTX 1660, 1660 Ti, the RTX 2060 (Super), 2070 (Super), 2080 (Super), 2080 Ti and the Titan RTX. The following QUADRO and TESLA products geared to the professional market also offer Turing NVENC support: Quadro T1000, T2000, Quadro RTX 3000, 4000, 5000, 6000, 8000 and Tesla T4.

Measurement methodology and basics

This quality comparison was carried out independently in the context of a bachelor thesis. The data set used was 11 uncompressed 1080p videos from the free video library xiph.org, a mix of gameplay, rendering and camera footage. The frame rates vary between 25 and 60 fps. Netflix VMAF was chosen as the reference metric, an AI-based reference method for determining subjective video quality and making it comparable. The method has been examined by independent institutes and is considered one of the best at present.

The scale goes from 0 to 100. The full 100 points correspond to the original video, 80 points a slight impairment of quality, below 60 points the quality is hardly acceptable. The test system uses an Intel i7-5820K @4.5 GHz, an NVIDIA RTX 2080 @1860 MHz (driver version 442.19), 32 GB DDR4 @2400 MHz, an Asus X99-Pro motherboard, a 1 TB SATA SSD and the Corsair AX860 as power supply. The Intel CPU of the test system is overclocked to 4.5 GHz on all cores to minimize a bottleneck in terms of graphics performance. Modern graphics cards automatically regulate their clock rate and thus their performance until a preset maximum temperature is reached. To ensure comparability between load tests, the clock rate of the RTX 2080 is manually set to 1860 MHz. In consecutive tests, the system waits until the GPU temperature drops below 50 °C before starting the next test. 

Figure 1: NVIDIA Turing GPU family Source: https://developer.nvidia.com/nvidia-video-codec-sdk

As shown in Figure 1, physical offloading of the encoder is intended to ensure that other tasks performed on the GPU are not affected in performance. Software-based x264 encoding places a heavy load on the CPU, leaving less CPU processing time available for other applications. With hardware-based encoding, the CPU is not burdened with the computationally intensive task of encoding, e.g. in computer games higher frame rates and thus a better gaming experience and better streaming performance are possible (Figure 2).

Figure 2 Nvidia NVENC vs x264 average FPS Source: https://obsproject.com/forum/resources/nvidia-nvenc-guide.740/

Nvidia’s figures on video quality should be treated with caution, however, as the PSNR metric used says little about perceived video quality but only measures the signal-to-noise ratio. The uncompressed reference videos were first converted with the free HandBrake encoder. Often an encoder program like OBS is used for live streaming. With OBS, however, it is not possible to make a frame-accurate comparison with the uncompressed reference file afterwards.

Such a comparison is a prerequisite for VMAF calculations, so the source videos are converted with HandBrake, which also eliminates possible performance problems of the test system, since the videos do not have to be converted in real time, unlike live streaming. The settings correspond to the recommendations of Twitch and YouTube Live (H.264, 1080p 60 FPS, 6 Mbit)

Video Encoder

H.264 (x264)

Frame rate

Same as source; constant frame rate

Default setting

Veryfast; faster; fast; medium

Average bit rate (kbps)

6000

Vote

None

Profile

High

Level

Car

Additional parameters

nal-hrd=cbr:bitrate=6000:vbv-bufsize=6000:vbv-maxrate=6000:qcomp=0.0:keyint=120:bframes=2

Danke für die Spende



Du fandest, der Beitrag war interessant und möchtest uns unterstützen? Klasse!

Hier erfährst Du, wie: Hier spenden.

Hier kannst Du per PayPal spenden.

About the author

Igor Wallossek

Editor-in-chief and name-giver of igor'sLAB as the content successor of Tom's Hardware Germany, whose license was returned in June 2019 in order to better meet the qualitative demands of web content and challenges of new media such as YouTube with its own channel.

Computer nerd since 1983, audio freak since 1979 and pretty much open to anything with a plug or battery for over 50 years.

Follow Igor:
YouTube Facebook Instagram Twitter

Werbung

Werbung