优化渲染效果

This commit is contained in:
锦恢 2024-11-22 22:23:11 +08:00
parent bb113deea5
commit 43f4245cac
3 changed files with 3 additions and 3 deletions

Binary file not shown.

View File

@ -140,7 +140,7 @@ const ladderAnalog_GL_WidthShifts = new Float32Array([
]);
const lineAnalog_WidthShift = 0.0015;
const lineAnalog_WidthShift = 0.002;
const lineAnlog_GL_WidthShifts = new Float32Array([
0, lineAnalog_WidthShift, // 0
- lineAnalog_WidthShift, lineAnalog_WidthShift, // 1

View File

@ -35,7 +35,7 @@ class WebGL2WaveRender {
const gl = canvas.getContext('webgl2', {
premultipliedAlpha: false,
alpha: true,
antialias: false,
antialias: true,
depth: false
});
this.webglLocation = this.initProgram(gl);
@ -507,7 +507,7 @@ class WebGL2WaveRender {
// 如果是 vec根据设定的渲染模式和进行设置
const vecRenderModal = _this.getVecRenderModal(globalLookup, signal.link);
if (vecRenderModal === 0) {
// 普通数字渲染模式
// 普通数字渲染模式
gl.uniform2fv(webglLocation.widthShifts, gl_WidthShifts);
gl.uniform2fv(webglLocation.shifts, gl_Shifts_for_bar);
gl.bindVertexArray(signalItem.lineVao);