Electronics > FPGA

Book on SMPTE SDI Protocol?

<< < (3/3)

Someone:

--- Quote from: jakubhladik1 on June 05, 2023, 04:26:19 pm ---I expect 8-bit RGB -> 10-bit YCbCr -> 8-bit RGB to be lossless as there are enough bits to carry the "fractional" portions of the converted color value without rounding.
--- End quote ---
You'd expect wrong! even with 16 bit intermediaries it won't be lossless in most implementations.

Scrts:

--- Quote from: jakubhladik1 on June 05, 2023, 04:26:19 pm ---I need HD-SDI + 3G-SDI, 6G-SDI as a bonus if I can run the 20-bit data path at 297 MHz. This is for DO-254 avionics application where we need to prove to the govt authorities that the code is safe. Very difficult to do with 3rd-party code, impossible to do with encrypted IP code. I got Rx IP working, I just need to add decoding of ancillary data to recognize whether the format being received is RGB or YCbCr and automatically switch between two different pixel unpacking and color space conversion. Xilinx XAPP514 has been extremely helpful.

On another note, is it expected that 10-10-10 bit RGB 4:4:4 -> 10-10-10 bit YCbCr 4:4:4 -> 10-10-10 bit RGB 4:4:4 conversion is lossy? I noticed due to rounding to integer in the color space conversion (ITU BT.709), the worst case error is the original component +/- 2 (+/- 1 when going from RGB -> YCbCr and another +/- 1 when converting back). I did not expect it but it makes sense in terms of the math. I expect 8-bit RGB -> 10-bit YCbCr -> 8-bit RGB to be lossless as there are enough bits to carry the "fractional" portions of the converted color value without rounding.

I've tried a couple values with my fixed-point decimal color converter and these are the results:

RGB [255, 0, 0] -> YCbCr [54, 482, 643] -> RGB [256, 0, 0]
RGB [940, 64, 64] -> YCbCr [250, 409, 960] -> RGB [940, 64, 63]
RGB [0, 255, 0] -> YCbCr [182, 412, 394] -> RGB [0, 254, 1]

Note that 255 is not the maximum value here, I just used it to show the integer rounding error.

--- End quote ---

Lossy for the machine? Or human eye? The application here is to deliver high resolution camera data into the airplane?

jakubhladik1:

--- Quote from: Scrts on June 05, 2023, 11:06:49 pm ---Lossy for the machine? Or human eye? The application here is to deliver high resolution camera data into the airplane?

--- End quote ---

Lossy for the machine, just thinking ahead for verification of expected values. Correct, camera feed going to a display.

jakubhladik1:

--- Quote from: Someone on June 05, 2023, 10:43:34 pm ---
--- Quote from: jakubhladik1 on June 05, 2023, 04:26:19 pm ---I expect 8-bit RGB -> 10-bit YCbCr -> 8-bit RGB to be lossless as there are enough bits to carry the "fractional" portions of the converted color value without rounding.
--- End quote ---
You'd expect wrong! even with 16 bit intermediaries it won't be lossless in most implementations.

--- End quote ---

Thank you for pointing this out.

Navigation

[0] Message Index

[*] Previous page

There was an error while thanking
Thanking...
Go to full version
Powered by SMFPacks Advanced Attachments Uploader Mod