parent
cd5b0e74e3
commit
e5bcc793e5
5 changed files with 239 additions and 46 deletions
11
app/shaders/egl_overlay.frag
Normal file
11
app/shaders/egl_overlay.frag
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
precision mediump float;
|
||||
uniform sampler2D uTexture;
|
||||
varying vec2 vTexCoord;
|
||||
|
||||
void main() {
|
||||
vec4 abgr = texture2D(uTexture, vTexCoord);
|
||||
|
||||
gl_FragColor = abgr;
|
||||
gl_FragColor.r = abgr.b;
|
||||
gl_FragColor.b = abgr.r;
|
||||
}
|
||||
8
app/shaders/egl_overlay.vert
Normal file
8
app/shaders/egl_overlay.vert
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
attribute vec2 aPosition; // 2D: X,Y
|
||||
attribute vec2 aTexCoord;
|
||||
varying vec2 vTexCoord;
|
||||
|
||||
void main() {
|
||||
vTexCoord = aTexCoord;
|
||||
gl_Position = vec4(aPosition, 0, 1);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue