Method GLUE.BaseTexture()->create_texture()
- Method
create_texture
void
create_texture(mapping
|void
imgs
,int(2bit)
|void
flags
,int
|void
width
,int
|void
height
)- Description
Actually creates the texture.
- Parameter
imgs
If zero, a black texture with the dimensions
width
*height
will be generated. Otherwiseimgs
should be a mapping as follows."image"
:Image.Image
The actual image to be used as texture. It will be cropped/padded to meet the dimensions given in
width
andheight
."alpha"
:Image.Image
Optional image to be used as alpha channel, depending on the alpha value given to create/construct.
- Parameter
flags
If
1
, the texture will be mipmapped. If bit 1 (2
) is set, texture will not be wrapped but clamped.- Parameter
width
- Parameter
height
The dimensions of the texture. If omitted the dimensions of the images in
imgs
will be used.- See also