ServersYour serverFor creatorsForumFAQDocumentationSecurity
Download the launcher
  1. Documentation
  2. Client functions
  3. dxGetMaterialSize

Function

dxGetMaterialSize

ClientDrawing (dx)Identical to MTA:SA

Returns the width and height of a material: a texture, a render target, a browser or a shader.

Syntax

int, int dxGetMaterialSize(element material)

Arguments

materialelement
The material.

Returns

Width and height or false.

Example

local w, h = dxGetMaterialSize(dxCreateTexture("img/logo.png"))

See also