WebGL - Reading pixels

In this episode, I discuss how to read the color from mouse clicks on the canvas in WebGL.
Concepts:
  • API: gl.readPixels
  • API: preserveDrawingBuffer
  • Type Array Uint8Array(4);

Resources:
  • https://github.com/davidwparker/programmingtil-webgl/tree/master/0033-reading-pixels
© programmingtil.com