NVENC/QSV Bug when rendering image sequence + HEVC media

ALO wrote on 2/20/2024, 12:06 PM

I'm able to recreate this with media created entirely within Vegas. For starters, I created a short (2 seconds) PNG image sequence of a default text media clip. When this image sequence is imported and then placed on the Vegas timeline preceding an HEVC file (I use 5K GoPro, but this also happens if I create a Main Concept HEVC 4K clip), renders using the NVENC or Intel QSV encoders garble and bleed the image sequence into the following HEVC clip.

Here's a screenshot of my timeline:

This doesn't happen when I switch to an AVC render, or a Mainconcept HEVC render. Maybe all those images are somehow being held in memory and then leaking into the render of the subsequent clip?

Current Vegas build, NVIDIA GPU

Comments

RogerS wrote on 2/20/2024, 8:57 PM

I tried this with a single PNG I had here and a 5K GoPro clip with 4K HEVC (NVENC) encoding but didn't recreate a glitch.

Next I tried creating text in the media generator and exporting PNGs then reimporting them as a sequence and putting these file before the GoPro and rendering to 4K HEVC/NVENC.

I also tested the same thing in VP 19 just in case it's different but there wasn't a glitch. I then tried with VP 19 and QSV. No glitch.

FWIW I have Intel doing decoding and NVIDIA doing timeline and encoding. Dynamic ram is set to 10%.

I went frame by frame in MPC Black but don't see a glitch. My hardware is much older (2017 era XPS 15) so may be different in VEGAS. Windows 10. Latest NVIDIA studio driver.

ALO wrote on 2/21/2024, 9:19 AM

It definitely does not happen for me with only a single PNG on the timeline. It requires a sequence of PNG (or JPEG). I'm using the latest NVIDIA studio driver also, but on a 2022 XPS with Win 11.

The bleed effect is very pronounced (the two clips are superimposed/garbled over each other after the image sequence ends). In this case I can render out using the Main Concept HEVC engine, so it's not a deal breaker. If I can come up with any other ways to trigger it, I'll post back. Thanks for trying to duplicate it!

Former user wrote on 2/21/2024, 5:39 PM

@RogerS It's a different variation of the broken full screen image problem I"ve shown in past. Vegas would have had this bug since VP15. There are likely many other variations.

Also I"m using AVC media, not HEVC

Voukoder shows correct operation. Magix encodes are broken, they do not show the 5 seconds of still image.

RogerS wrote on 2/21/2024, 7:26 PM

It definitely does not happen for me with only a single PNG on the timeline. It requires a sequence of PNG (or JPEG). I'm using the latest NVIDIA studio driver also, but on a 2022 XPS with Win 11.

The bleed effect is very pronounced (the two clips are superimposed/garbled over each other after the image sequence ends). In this case I can render out using the Main Concept HEVC engine, so it's not a deal breaker. If I can come up with any other ways to trigger it, I'll post back. Thanks for trying to duplicate it!

If you have other ideas (or a sample project) I'm willing to test again, especially as I use timelapses in my work. I believe it exists and replication should bring us closer to solving it.

Former user wrote on 2/22/2024, 3:13 PM

@ALO I tried how (I think) you described, but do not see an encoding defect, the cat picture however causes the video to freeze but that problem is unrelated to HEVC video

Video being used is DJI HEVC 420 10BIT

Former user wrote on 2/22/2024, 4:48 PM

@ALO In the past I learnt to use Mainconcept to render anything with png's (pics/text) because NVENC messes with the pictures. (Not always but it's not guaranteed NV won't mess it up so it's safer to not use that option)

This is a 5.3 GoPro, a text png sequence & a couple of png pics.

I've only done one test with two renders,

With Magix HEVC NV Encoder

With Magix HEVC Mainconcept

This is just one test but from past experience of trial n error with the settings I don't believe there's anything I can do to change this...

 

Former user wrote on 2/22/2024, 5:14 PM

@Former user Tried twice with Magix NVENC HEVC, looked fine, tried once with Magix NVENC AVC, got the artifacting OP describes.

 

 

Former user wrote on 2/22/2024, 5:22 PM

@Former user I normally use AVC & haven't recently (2023-24) made any videos so haven't had to deal with this.

The ones I did above are Magix HEVC but the project was/is still on the timeline so I tried it with Magix AVC NV Encoder,

Just one render gave the same glitch as my Magix HEVC NV Encoder which is similar to yours,

ALO wrote on 2/23/2024, 11:00 AM

@Former user Tried twice with Magix NVENC HEVC, looked fine, tried once with Magix NVENC AVC, got the artifacting OP describes.

 

 

thank you everyone for the repo! Hope this gets fixed

Former user wrote on 2/23/2024, 5:14 PM

This has been a fault since 2017,so it appears they have no plans to fix. As a coverup the meme of 'hardware encoding is low quality' was created in the Vegas forums. And everyone here parroted the same, even though the developers knew the hundreds of complaints were valid, and the artifacting was due to bugs.

VP17 is earliest Vegas I have it behaves the same,

RogerS wrote on 2/23/2024, 9:50 PM

The NVIDIA NVENC graphics glitch dates to VP15 I believe. That's when I first encountered it

That's not related to hardware renders are low quality, which I remember being more about earlier implementations of QSV.

Former user wrote on 2/23/2024, 11:14 PM

@RogerS , @ALO said he see's the artifacting from his demonstration on QSV and NVENC, you don't feel that could contribute to glitching with QSV in general and could have similar problems?

But you do say you've noticed glitching with NVENC for a long time, and I'd guess by now you're experienced enough with QSV to say it doesn't happen or rare in comparision?

RogerS wrote on 2/24/2024, 12:15 AM

I saw glitching until VP19 connected with NVENC and dynamic ram preview. I don't really see it often anymore as the devs did listen and address it (I was one of the many reports of this problem).

These days I do draft renders with MagixAVC and NVENC and final through x264 and Voukoder (usually).

I haven't seen glitches with QSV encoding but also don't often use it so don't doubt others reports.

For render quality if matters for a GPU encode I give it more bitrate to work with. I see its tradeoff with datarate inefficiency as a different issue than artifacts.

Former user wrote on 2/24/2024, 2:54 AM

@RogerS Try a test with this file https://www.dropbox.com/scl/fi/52jv1c76dop3dxn6jli8o/input-render-test.mp4?rlkey=wuh4oybmpvf2o9b0dup8wpdhy&dl=0

Use MAGIX AVC NVENC 2160P 59.94 render template, change the frame rate to match project 23.976. Do same with QSV.

If either of the encodes are different to the original describe.

Wolfgang S. wrote on 2/24/2024, 3:51 AM

I find here significant differences - between the QSV encoded footage and the original footage. The NENC footage seems to be quite similar to the original footage.

Original:

Intel QSV encoded footage:

 

Is that what you were looking for?

 

Desktop: PC AMD 3960X, 24x3,8 Mhz * RTX 3080 Ti (12 GB)* Blackmagic Extreme 4K 12G * QNAP Max8 10 Gb Lan * Resolve Studio 18 * Edius X* Blackmagic Pocket 6K/6K Pro, EVA1, FS7

Laptop: ProArt Studiobook 16 OLED * internal HDR preview * i9 12900H with i-GPU Iris XE * 32 GB Ram) * Geforce RTX 3070 TI 8GB * internal HDR preview on the laptop monitor * Blackmagic Ultrastudio 4K mini

HDR monitor: ProArt Monitor PA32 UCG-K 1600 nits, Atomos Sumo

Others: Edius NX (Canopus NX)-card in an old XP-System. Edius 4.6 and other systems

Former user wrote on 2/24/2024, 4:22 AM

@Wolfgang S. it encodes like this for me (Nvenc)

 

I"m using the 2nd most recent Nvidia studio drivers. If nobody else shows the same I"ll reset Vegas

 

Wolfgang S. wrote on 2/24/2024, 4:46 AM

Hard to say what you should do. I can confirm only, that I do not see the colored artefacts in my nvenc supported AVC rendering - that your video shows in the beginning in the cat part of the video. I have found another issue with QSV encoding, and that is something that I have reported.

But you should be aware that I am using an old nvidia driver (522.30) for the simple reason, that this works for me. And there are for sure differences in the testing enviroment that I use here, too.

So it is hard to give you an advice how to proceed. Maybe it is worthwhile to reset Vegas, but then I would recommend to export the preferences before you do so (Options/Export preferences).

But frankly spoken, my expecation (and I may be wrong here) is, that it could be that a reset is not the solution. Maybe it is a driver issue, maybe it is a issue in the actual version of Vegas you use, maybe both of it. So you can only try, maybe reset Vegas, but also think about to deinstall the nvidia driver you use, and test an older one - and see if that shows positive results.

 

 

Last changed by Wolfgang S. on 2/24/2024, 4:47 AM, changed a total of 1 times.

Desktop: PC AMD 3960X, 24x3,8 Mhz * RTX 3080 Ti (12 GB)* Blackmagic Extreme 4K 12G * QNAP Max8 10 Gb Lan * Resolve Studio 18 * Edius X* Blackmagic Pocket 6K/6K Pro, EVA1, FS7

Laptop: ProArt Studiobook 16 OLED * internal HDR preview * i9 12900H with i-GPU Iris XE * 32 GB Ram) * Geforce RTX 3070 TI 8GB * internal HDR preview on the laptop monitor * Blackmagic Ultrastudio 4K mini

HDR monitor: ProArt Monitor PA32 UCG-K 1600 nits, Atomos Sumo

Others: Edius NX (Canopus NX)-card in an old XP-System. Edius 4.6 and other systems

Former user wrote on 2/24/2024, 6:43 AM

@Wolfgang S. Hi, from my experience this has been an issue with all versions of VP since my first VP18 & all drivers that have been released since,

Wolfgang S. wrote on 2/24/2024, 6:57 AM

Can be. Funny enough, that I do not see this issue in my test environement with the clip delivered by Todd. ;)

Last changed by Wolfgang S. on 2/24/2024, 7:00 AM, changed a total of 1 times.

Desktop: PC AMD 3960X, 24x3,8 Mhz * RTX 3080 Ti (12 GB)* Blackmagic Extreme 4K 12G * QNAP Max8 10 Gb Lan * Resolve Studio 18 * Edius X* Blackmagic Pocket 6K/6K Pro, EVA1, FS7

Laptop: ProArt Studiobook 16 OLED * internal HDR preview * i9 12900H with i-GPU Iris XE * 32 GB Ram) * Geforce RTX 3070 TI 8GB * internal HDR preview on the laptop monitor * Blackmagic Ultrastudio 4K mini

HDR monitor: ProArt Monitor PA32 UCG-K 1600 nits, Atomos Sumo

Others: Edius NX (Canopus NX)-card in an old XP-System. Edius 4.6 and other systems

RogerS wrote on 2/24/2024, 7:59 AM

I appreciate a good test!

I see a ton of render artifacts in the NVENC render:

Completely unusable.

The QSV render looked similar to the source though there are the usual compression issues (mild blocking)..

j-v wrote on 2/24/2024, 9:05 AM

I'm seeing the same with the NVENC render, also with the older driver 522.30


No problem with QSV or Mainconcept rendering

met vriendelijke groet
Marten

Camera : Pan X900, GoPro Hero7 Hero Black, DJI Osmo Pocket, Samsung Galaxy A8
Desktop :MB Gigabyte Z390M, W11 home version 24H2, i7 9700 4.7Ghz,16 DDR4 GB RAM, Gef. GTX 1660 Ti with driver
566.14 Studiodriver and Intel HD graphics 630 with driver 31.0.101.2130
Laptop  :Asus ROG Str G712L, W11 home version 23H2, CPU i7-10875H, 16 GB RAM, NVIDIA GeForce RTX 2070 with Studiodriver 576.02 and Intel UHD Graphics 630 with driver 31.0.101.2130
Vegas software: VP 10 to 22 and VMS(pl) 10,12 to 17.
TV      :LG 4K 55EG960V

My slogan is: BE OR BECOME A STEM CELL DONOR!!! (because it saved my life in 2016)

 

Wolfgang S. wrote on 2/24/2024, 10:24 AM

Have repeated the test twice. Now I see artefacts also in the NVENC samples - but there is still nothing in the first render test. Funny.

Desktop: PC AMD 3960X, 24x3,8 Mhz * RTX 3080 Ti (12 GB)* Blackmagic Extreme 4K 12G * QNAP Max8 10 Gb Lan * Resolve Studio 18 * Edius X* Blackmagic Pocket 6K/6K Pro, EVA1, FS7

Laptop: ProArt Studiobook 16 OLED * internal HDR preview * i9 12900H with i-GPU Iris XE * 32 GB Ram) * Geforce RTX 3070 TI 8GB * internal HDR preview on the laptop monitor * Blackmagic Ultrastudio 4K mini

HDR monitor: ProArt Monitor PA32 UCG-K 1600 nits, Atomos Sumo

Others: Edius NX (Canopus NX)-card in an old XP-System. Edius 4.6 and other systems

Former user wrote on 2/24/2024, 4:57 PM

This is a comparison of 2 MAGIX NVENC encodes, and a slightly different test, The top encode at the lower bitrate is successful it shows the cat, the bottom encode does not show a cat, although it should. The problem looks to be related to the much lower bitrate P frame at position 102, which will forbid the cat from appearing, probably for as long as the cat is shown. I've tested a maximum of 10 seconds of cat, but no cat is encoded.

frame 102 is where the jpg first appears on timeline

RogerS wrote on 2/24/2024, 11:38 PM

On my desktop I see issues with both QSV and NVENC renders. My laptop (GTX 1050) is on the current studio driver, desktop is on the one before it (haven't yet installed the latest).

NVENC:

QSV dynamic ram preview 10%:

and DRP 0 (didn't help)