deck.gl icon indicating copy to clipboard operation
deck.gl copied to clipboard

picking feature issue: glScissor: width < 0

Open rivulet-zhang opened this issue 9 years ago • 4 comments

This occasionally occurs during the program initialization stage. The last line (192 messages) was triggered by mouse-moving on the map. screen shot 2017-07-11 at 4 08 35 pm I was working on the tagmap example, but it occurred even though I disabled my code. Seems to be relevant to the picking feature in deck.gl.

rivulet-zhang avatar Jul 11 '17 20:07 rivulet-zhang

@rivulet-zhang This should have been fixed by https://github.com/uber/deck.gl/pull/756 Try install the latest beta.

Pessimistress avatar Jul 11 '17 22:07 Pessimistress

Hi @Pessimistress both beta.2 and beta.4 still have this issue. Here is the line of code that generates the negative width value in draw-and-pick.js: const width = Math.min(pickingFBO.width, deviceX + deviceRadius) - x + 1;

When it occurs, I saw that the picking frame buffer (pickingFBO) had the size of 1000 (the default setting?) while the mouse position (deviceX) was outside the box. It looks like the frame buffer was not resized correctly.

rivulet-zhang avatar Jul 12 '17 14:07 rivulet-zhang

1000 is the default canvas size. Sounds like the canvas and picking framebuffer sizes are out of sync. Can you try change componentDidMount to componentWillMount in app.js and see if the problem goes away?

Pessimistress avatar Jul 12 '17 15:07 Pessimistress

That fixed the issue. Thanks!

rivulet-zhang avatar Jul 12 '17 17:07 rivulet-zhang