Last change
on this file since 79605 was 71027, checked in by vboxsync, 7 years ago |
FE/Qt: big svn props cleanup
|
-
Property svn:eol-style
set to
native
-
Property svn:keywords
set to
Author Date Id Revision
|
File size:
541 bytes
|
Line | |
---|
1 | /* $Id: cconvUYVY.c 71027 2018-02-15 14:33:48Z vboxsync $ */
|
---|
2 | #extension GL_ARB_texture_rectangle : enable
|
---|
3 | uniform sampler2DRect uSrcTex;
|
---|
4 | void vboxCConvApplyAYUV(vec4 color);
|
---|
5 | void vboxCConv()
|
---|
6 | {
|
---|
7 | vec2 srcCoord = vec2(gl_TexCoord[0]);
|
---|
8 | float x = srcCoord.x;
|
---|
9 | int pix = int(x);
|
---|
10 | vec4 srcClr = texture2DRect(uSrcTex, vec2(float(pix), srcCoord.y));
|
---|
11 | float u = srcClr.b;
|
---|
12 | float v = srcClr.r;
|
---|
13 | float part = x - float(pix);
|
---|
14 | float y;
|
---|
15 | if(part < 0.5)
|
---|
16 | {
|
---|
17 | y = srcClr.g;
|
---|
18 | }
|
---|
19 | else
|
---|
20 | {
|
---|
21 | y = srcClr.a;
|
---|
22 | }
|
---|
23 | vboxCConvApplyAYUV(vec4(u, y, 0.0, v));
|
---|
24 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.