|
|
@ -68,7 +68,7 @@ const sdf_vs_src = `#version 300 es |
|
|
|
screen02 += vec2(100.0); // shift offscreen
|
|
|
|
screen02 += vec2(100.0); // shift offscreen
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
gl_Position = vec4(screen02 - 1.0, (float(stroke_index) / float(u_stroke_count)) * 2.0 - 1.0, 1.0); |
|
|
|
gl_Position = vec4(screen02 - 1.0, (float(stroke_index + 1) / float(u_stroke_count)) * 2.0 - 1.0, 1.0); |
|
|
|
} |
|
|
|
} |
|
|
|
`;
|
|
|
|
`;
|
|
|
|
|
|
|
|
|
|
|
@ -323,10 +323,8 @@ function init_webgl(state, context) { |
|
|
|
gl.enable(gl.BLEND); |
|
|
|
gl.enable(gl.BLEND); |
|
|
|
gl.blendFunc(gl.ONE, gl.ONE_MINUS_SRC_ALPHA); |
|
|
|
gl.blendFunc(gl.ONE, gl.ONE_MINUS_SRC_ALPHA); |
|
|
|
|
|
|
|
|
|
|
|
/* |
|
|
|
|
|
|
|
gl.enable(gl.DEPTH_TEST); |
|
|
|
gl.enable(gl.DEPTH_TEST); |
|
|
|
gl.depthFunc(gl.NOTEQUAL); |
|
|
|
gl.depthFunc(gl.NOTEQUAL); |
|
|
|
*/ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
context.gpu_timer_ext = gl.getExtension('EXT_disjoint_timer_query_webgl2'); |
|
|
|
context.gpu_timer_ext = gl.getExtension('EXT_disjoint_timer_query_webgl2'); |
|
|
|
if (context.gpu_timer_ext === null) { |
|
|
|
if (context.gpu_timer_ext === null) { |
|
|
|