Differential D16125 Diff 56366 source/blender/draw/engines/overlay/shaders/overlay_motion_path_line_vert.glsl
Changeset View
Changeset View
Standalone View
Standalone View
source/blender/draw/engines/overlay/shaders/overlay_motion_path_line_vert.glsl
| Show All 12 Lines | vec2 proj(vec4 pos) | ||||
| return (0.5 * (pos.xy / pos.w) + 0.5) * sizeViewport.xy; | return (0.5 * (pos.xy / pos.w) + 0.5) * sizeViewport.xy; | ||||
| } | } | ||||
| #define SET_INTENSITY(A, B, C, min, max) \ | #define SET_INTENSITY(A, B, C, min, max) \ | ||||
| (((1.0 - (float(C - B) / float(C - A))) * (max - min)) + min) | (((1.0 - (float(C - B) / float(C - A))) * (max - min)) + min) | ||||
| void main() | void main() | ||||
| { | { | ||||
| gl_Position = drw_view.persmat * vec4(pos, 1.0); | gl_Position = drw_view.winmat * (drw_view.viewmat * vec4(pos, 1.0)); | ||||
| interp.ss_pos = proj(gl_Position); | interp.ss_pos = proj(gl_Position); | ||||
| int frame = gl_VertexID + cacheStart; | int frame = gl_VertexID + cacheStart; | ||||
| float intensity; /* how faint */ | float intensity; /* how faint */ | ||||
| vec3 blend_base = (abs(frame - frameCurrent) == 0) ? | vec3 blend_base = (abs(frame - frameCurrent) == 0) ? | ||||
| ▲ Show 20 Lines • Show All 58 Lines • Show Last 20 Lines | |||||