oframe / ogl

Minimal WebGL Library
https://oframe.github.io/ogl/examples
3.77k stars 213 forks source link

fix: missing HTMLCanvasElement type in Texture.d.ts #198

Closed Jeremboo closed 8 months ago

Jeremboo commented 11 months ago

I'm using a canvas as texture and it's working perfectly!

const myTexture = new Texture(gl);
myTexture.image = myCanvas.canvas;

But typescript complains because HTMLCanvasElement is not part of the typing ImageRepresnetation.

pschroen commented 9 months ago

LGTM

pschroen commented 8 months ago

@gordonnl bump ☝️😉