Name
gl.GetTexImageToBrush -- return a texture image as a brush
Synopsis
[id] = gl.GetTexImageToBrush(target, level, id)
Function
This function does the same as gl.GetTexImage() except that the pixel data is converted into the Hollywood brush specified by id. If there is already a brush that uses the identifier id, it will be freed first. If you specify Nil in the id argument, gl.GetTexImageToBrush() will automatically choose a vacant identifier for this brush and return it to you.

See gl.GetTexImage for details.

Inputs
target
specifies which texture is to be obtained (must be #GL_TEXTURE_1D or #GL_TEXTURE_2D)
level
specifies the level-of-detail number of the desired image; level 0 is the base image level; level n is the nth mipmap reduction image
id
id for the new brush or Nil for auto id selection
Results
id
optional: identifier of the brush; will only be returned when you pass Nil as argument 3 (see above)

Show TOC