draw.TexturedQuad

From Garry's Mod
Jump to: navigation, search
 draw.TexturedQuad( )

Contents

Description

Draws a texture with a table structure.

NOTE

This is a rendering function that requires a 2D rendering context.
This means that it will only work in hooks with a 2D rendering context.

Arguments

table texturedata

The texture properties. See TextureData structure

Examples

Example

Example usage

local TexturedQuadStructure = {
	texture = surface.GetTextureID( 'phoenix_storms/amraam' ),
	color   = Color( 255, 0, 255, 255 ),
	x 	= 0,
	y 	= 0,
	w 	= 512,
	h 	= 512
}
draw.TexturedQuad( TexturedQuadStructure )

Output:

Renders the texture.
Personal tools
Navigation