• Advertisement
Sign in to follow this  

webgl :create a texture with javascript

This topic is 2338 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

hello.
I have a huge number of object that change only for the color and the dimension.
I wish store all the colors and scale factor in a texture for don't call 3242134142 webgl draw .
The model is a static model .

how i can create a texture with javascript and webgl?
Is possible?
thanks.

Share this post


Link to post
Share on other sites
Advertisement
The following: "I wish store all the colors and scale factor in a texture for don't call 3242134142 webgl draw" , made absolutely no sense to me.

Anyway, to try and answer your question "how i can create a texture with javascript and webgl?", you could use a canvas element to generate an image which could then be used as a texture.

If all you want to do it alter the color, then perhaps you could do that in the shared instead.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement