From de639512899a7c864470baec1b59796a5f36eb36 Mon Sep 17 00:00:00 2001 From: Dmitry Date: Thu, 3 May 2018 13:29:23 -0400 Subject: [PATCH 1/2] Add null-data buffer fix --- src/traces/parcoords/lines.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/traces/parcoords/lines.js b/src/traces/parcoords/lines.js index 88386402689..2de3e8d397c 100644 --- a/src/traces/parcoords/lines.js +++ b/src/traces/parcoords/lines.js @@ -176,7 +176,7 @@ function setAttributes(attributes, sampleCount, points) { function emptyAttributes(regl) { var attributes = {}; for(var i = 0; i < 16; i++) { - attributes['p' + i.toString(16)] = regl.buffer({usage: 'dynamic', type: 'float', data: null}); + attributes['p' + i.toString(16)] = regl.buffer({usage: 'dynamic', type: 'float', data: new Uint8Array()}); } return attributes; } From 5d38e888bb4688a7217e47d63df5e85aa036ba5c Mon Sep 17 00:00:00 2001 From: Dmitry Date: Tue, 22 May 2018 15:31:37 -0400 Subject: [PATCH 2/2] Add zero arg to TypedArray --- src/traces/parcoords/lines.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/traces/parcoords/lines.js b/src/traces/parcoords/lines.js index 2de3e8d397c..5861eaffa70 100644 --- a/src/traces/parcoords/lines.js +++ b/src/traces/parcoords/lines.js @@ -176,7 +176,7 @@ function setAttributes(attributes, sampleCount, points) { function emptyAttributes(regl) { var attributes = {}; for(var i = 0; i < 16; i++) { - attributes['p' + i.toString(16)] = regl.buffer({usage: 'dynamic', type: 'float', data: new Uint8Array()}); + attributes['p' + i.toString(16)] = regl.buffer({usage: 'dynamic', type: 'float', data: new Uint8Array(0)}); } return attributes; }