jetson-ffmpeg icon indicating copy to clipboard operation
jetson-ffmpeg copied to clipboard

Force Decoding of Yuv420p10- Truncate to 8 bit needed

Open FCLC opened this issue 3 years ago • 5 comments

For cases where 10 bit signals may be sent to the decoder, the encoder on the nano cannot output 10 bit content. it can however accept a 10 bit source, truncate the data and output to 8 bit

FCLC avatar Feb 11 '21 22:02 FCLC

+1

AnterCreeper avatar Nov 19 '21 13:11 AnterCreeper

It will generate strange picture.

AnterCreeper avatar Nov 19 '21 13:11 AnterCreeper

Yes and no. Assuming the truncation is on the least significant bits, we lose minor detail.

The issue is in how different algorithms allocate bandwidth to different areas of the luminance curve.

In a linear scale we'd be bit shifting everything by 2 equally and having a linear change

But since HEVC, h264, and vp9 amongst other codecs dedicate more bandwidth to the lower parts of the curve that the upper parts, we can "afford" to lose more of the lower detail bits, as it is partially compensated by the disproportionately increased amount of data allocated to those sections.

If the truncation assumes the wrong type of endianness in its implementation, then the picture will be awful, as the wrong bits will have been "promoted" to the wrong area

FCLC avatar Nov 23 '21 03:11 FCLC

It seems that l4t multimedia api supports 10 bit. Am I interpreting this correctly? I'm going to try and add this feature but I'm really not sure what I'm doing 😅

mattangus avatar Nov 28 '21 16:11 mattangus

It seems that l4t multimedia api supports 10 bit. Am I interpreting this correctly? I'm going to try and add this feature but I'm really not sure what I'm doing sweat_smile

it is in the API, yes!

FCLC avatar Dec 07 '21 19:12 FCLC