pex-gl / pex-context

Modern WebGL state wrapper for PEX: allocate GPU resources (textures, buffers), setup state pipelines and passes, and combine them into commands.
http://pex-gl.github.io/pex-context/
MIT License
160 stars 12 forks source link

Add support for clearBuffer #139

Open dmnsgn opened 5 months ago

dmnsgn commented 5 months ago

MDN clearBuffer

vorg commented 5 months ago

as in e.g. array of colors in clearColor ? Yes, please.

ctx.pass({
  color: [colorBufferTex, normalBufferTex],
  clearColor: [[0, 0, 0, 1], [0, 0, 1, 1]], 
})