Class cc.Texture2DWebGL
- Defined in: CCTexture2D.js
- Extends cc.Class
Constructor Attributes | Constructor Name and Description |
---|---|
This class allows to easily create OpenGL 2D textures from images, text or raw data. |
Class Detail
cc.Texture2DWebGL()
This class allows to easily create OpenGL 2D textures from images, text or raw data.
The created cc.Texture2D object will always have power-of-two dimensions.
Depending on how you create the cc.Texture2D object, the actual image area of the texture might be smaller than the texture dimensions
i.e. "contentSize" != (pixelsWide, pixelsHigh) and (maxS, maxT) != (1.0, 1.0).
Be aware that the content of the generated textures will be upside-down!