Extended Dynamic Range support in NVDEC

Hi,

Trying to analyze various samples, decoded with NVDEC, I noticed all of them are decoded into narrowed dynamic range of 16-235, disregarding the video_full_range_flag field in SPS. I noticed also, that CUVIDH264PICPARAMS structure, which goes as an input to the decoder, does not contain any reference to DR setting. My question is, if there is any way make decoder respect the dynamic range as it was encoded. (I’m rather noob in video business, so don’t judge hard if i’m asking for nonsense)

Regards

Can you post a link to one of these samples so that we can try some experiments? Also to test with other decoders.

Here’s an example of full DR, which after been decoded shows restricted DR in the histogram

https://www.dropbox.com/s/06zmej8yer16omt/test.264?dl=0

Thanks, I’ll have a look at it today. Meanwhile, do you know of any other decoders that deliver full DR for this file?

Not that I’m aware of. Our legacy, CPU based decoder does not as well, but this because it skips the video_full_range_flag intentionally.

So we cannot rule out that the actual content has limited range, even though the flags are set.

Maybe an nVidia person can comment further but my understanding is that the decoder must deliver exactly what is coded, i.e., it doesn’t do any clipping or compression of values. Also, my understanding is that the flags are there only to guide any subsequent conversion to RGB.

Yes, this is my understanding as well as it goes. Probably the post-processing pipeline is in charge. Thanks for the effort anyways!