greggman / tdl

A low-level WebGL library
283 stars 39 forks source link

setTextureFromArray does not bind texture #8

Closed pnp2084 closed 9 years ago

pnp2084 commented 9 years ago

setTextureFromArray() takes a texture parameter tex but does not call gl.bindTexture() (or even use the parameter at all). As a result the last bound texture gets modified instead of the passed in texture.

greggman commented 9 years ago

Doh! How did it ever work :( Fixing

greggman commented 9 years ago

pushed version 0.0.33 with that fix. Please check.

greggman commented 9 years ago

Oh wait, I was thinking twgl not tdl. Sorry. I haven't uploaded a fix for tdl

pnp2084 commented 9 years ago

Excellent, fixed, and thanks! The bug was in twgl, I posted to the wrong project. (Doh)

BTW, thanks for the library--it made it easy to get to the real work (some shaders) instead of having to wade through the the OpenGL API.