Revision 7a5e538a
Added by Leszek Koltunski over 5 years ago
src/main/res/raw/main_vertex_shader.glsl | ||
---|---|---|
36 | 36 |
|
37 | 37 |
uniform mat4 u_MVPMatrix; // the combined model/view/projection matrix. |
38 | 38 |
uniform mat4 u_MVMatrix; // the combined model/view matrix. |
39 |
uniform float u_Inflate; // how much should we inflate (>0.0) or deflate (<0.0) the mesh. |
|
39 | 40 |
|
40 | 41 |
#if NUM_VERTEX>0 |
41 | 42 |
uniform int vNumEffects; // total number of vertex effects |
... | ... | |
144 | 145 |
|
145 | 146 |
void main() |
146 | 147 |
{ |
147 |
vec3 v = 2.0*u_objD*a_Position;
|
|
148 |
vec3 v = 2.0*u_objD*(a_Position + u_Inflate*a_Inflate);
|
|
148 | 149 |
vec3 n = a_Normal; |
149 | 150 |
|
150 | 151 |
#if NUM_VERTEX>0 |
Also available in: Unified diff
Progress with Inflate (building block of postprocessing effects: the proper way of marking a halo around a Mesh)
'Inflate' app testing the machanism. MeshFlat appears to be working, now we only need to fill up the per-vertex Inflate vector in the MeshCubes.