How i.mx6 GPU convert UYVY to RGB?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How i.mx6 GPU convert UYVY to RGB?

1,688 Views
linya
Contributor II

The glTextDirectVIVMap API is able to load UYVY texture.
What is the accurate algorithm that API convert UYVY to RGB ?

 

I found this algorithm for G2D from Processor Reference Manual.
16 <= Y <= 235
16 <= U <= 240
16 <= V <= 240
A = Y - 16
B = U - 128
C = V - 128
R = clip(( 298*A + 410*C + 128) >> 8)
G = clip((298*A - 101*B - 209*C + 128) >> 8)
B = clip((298*A + 519*B + 128) >> 8)

Is glTextDirectVIVMap API the same as G2D ?
I want to get a precise calculation of the GPU.

Any information is very appreciate.

Labels (3)
0 Kudos
2 Replies

1,062 Views
igorpadykov
NXP Employee
NXP Employee

Hi lin

please check sect.2.4.1 Color space conversion from YUV to RGB attached Graphics User Guide
and Chapter 13 Graphics Processing Unit (GPU) Linux Guide, as mentions sect.13.1.1.6
driver provides proprietary binary libraries, so not all its sources may be available.

Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos

1,062 Views
JohnDoe1z
Contributor III

Igor,

I'm also interested in the exact conversion done by the 3D GPU when using glTextDirectVIV. I checked the sections you referenced, but I cannot see how this would help to answer Lin Ya's and my question.

2.4.1 Color space conversion from YUV to RGB:

nice example, but it neither mentions how the conversion is done by the G2D API (which by the way Lin Ya already found) nor does it even mention the 3D GPU

Sect.13.1.1.6 of Chapter 13 Graphics Processing Unit (GPU):
also nice to know that some binaries are proprietary and not all sources are available, but currently I'm not interested in any sources. I just want to know the conversion factors used by the GPU which I refuse to believe is in any way "confidential".

0 Kudos