Changeset 646f3f2 in opengl-game for explosion.vert


Ignore:
Timestamp:
Jan 30, 2019, 3:10:23 AM (6 years ago)
Author:
Dmitry Portnoy <dmp1488@…>
Branches:
feature/imgui-sdl, master, points-test
Children:
39ac76d
Parents:
fe5e3ca
Message:

Make explosions render correctly whenever a ship is destroyed.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • explosion.vert

    rfe5e3ca r646f3f2  
    55uniform mat4 view, proj;
    66uniform mat4 model_mat;
    7 
    8 /*
    97layout (std140) uniform models {
    108  mat4 model_mats[MAX_NUM_OBJECTS];
    119};
    12 */
    1310
    1411uniform float explosion_start_time;
     
    4340   p += normalize(v_i) * mod(t, duration) / duration * 0.3; // allow time to loop around so particle emitter keeps going
    4441
    45    //gl_Position = proj * view * model_mats[0] * vec4(p, 1.0);
    46    gl_Position = proj * view * model_mat * vec4(p, 1.0);
     42   //gl_Position = proj * view * model_mats[ubo_index] * vec4(p, 1.0);
     43   gl_Position = proj * view * model_mats[0] * vec4(p, 1.0);
    4744   gl_PointSize = 15.0; // size in pixels
    4845}
Note: See TracChangeset for help on using the changeset viewer.