Revision 5ec42229
Added by Leszek Koltunski about 3 years ago
src/main/res/raw/blit_depth_vertex_shader.glsl | ||
---|---|---|
22 | 22 |
in vec2 a_Position; // Per-vertex position. |
23 | 23 |
out vec2 v_TexCoordinate; // |
24 | 24 |
|
25 |
uniform float u_Depth; // distance from the near plane to render plane, in clip coords |
|
26 | 25 |
uniform vec2 u_TexCorr; // when we blit from postprocessing buffers, the buffers can be |
27 | 26 |
// larger than necessary (there is just one static set being |
28 | 27 |
// reused!) so we need to compensate here by adjusting the texture |
... | ... | |
33 | 32 |
void main() |
34 | 33 |
{ |
35 | 34 |
v_TexCoordinate = (a_Position + 0.5) * u_TexCorr; |
36 |
gl_Position = vec4(2.0*a_Position,u_Depth,1.0);
|
|
35 |
gl_Position = vec4(2.0*a_Position,0.0,1.0);
|
|
37 | 36 |
} |
Also available in: Unified diff
Workaround for the fact that one some devices (for example the LG K30's V@415 driver on the Adreno 308) the Glow halo wasn't visible.