130 lines
		
	
	
		
			4.9 KiB
		
	
	
	
		
			Lua
		
	
	
	
	
	
			
		
		
	
	
			130 lines
		
	
	
		
			4.9 KiB
		
	
	
	
		
			Lua
		
	
	
	
	
	
---@meta
 | 
						|
 | 
						|
---@class Texture : Region
 | 
						|
Texture = {
 | 
						|
	--- Adds a mask texture to the texture.
 | 
						|
	--- @param mask Texture The mask texture to add.
 | 
						|
	--- @example
 | 
						|
	--- myTexture:AddMaskTexture(myMaskTexture)
 | 
						|
	AddMaskTexture = function(self, mask) end,
 | 
						|
 | 
						|
	--- Returns the mask texture at the specified index.
 | 
						|
	--- @param index number The index of the mask texture.
 | 
						|
	--- @return Texture mask The mask texture at the specified index.
 | 
						|
	--- @example
 | 
						|
	--- local mask = myTexture:GetMaskTexture(1)
 | 
						|
	GetMaskTexture = function(self, index) end,
 | 
						|
 | 
						|
	--- Returns the number of mask textures applied to the texture.
 | 
						|
	--- @return number count The number of mask textures.
 | 
						|
	--- @example
 | 
						|
	--- local count = myTexture:GetNumMaskTextures()
 | 
						|
	GetNumMaskTextures = function(self) end,
 | 
						|
 | 
						|
	--- Removes a mask texture from the texture.
 | 
						|
	--- @param mask Texture The mask texture to remove.
 | 
						|
	--- @example
 | 
						|
	--- myTexture:RemoveMaskTexture(myMaskTexture)
 | 
						|
	RemoveMaskTexture = function(self, mask) end,
 | 
						|
 | 
						|
	--- Gets the blend mode of the texture.
 | 
						|
	--- @return string mode The blend mode.
 | 
						|
	--- @example
 | 
						|
	--- local mode = myTexture:GetBlendMode()
 | 
						|
	GetBlendMode = function(self) end,
 | 
						|
 | 
						|
	--- Gets the texture coordinates.
 | 
						|
	--- @return number ULx, number ULy, number LLx, number LLy, number URx, number URy, number LRx, number LRy
 | 
						|
	--- @example
 | 
						|
	--- local ULx, ULy, LLx, LLy, URx, URy, LRx, LRy = myTexture:GetTexCoord()
 | 
						|
	GetTexCoord = function(self) end,
 | 
						|
 | 
						|
	--- Gets the texture path.
 | 
						|
	--- @return string texturePath The texture path.
 | 
						|
	--- @example
 | 
						|
	--- local texturePath = myTexture:GetTexture()
 | 
						|
	GetTexture = function(self) end,
 | 
						|
 | 
						|
	--- Gets the vertex color.
 | 
						|
	--- @return number r, number g, number b, number a The color components.
 | 
						|
	--- @example
 | 
						|
	--- local r, g, b, a = myTexture:GetVertexColor()
 | 
						|
	GetVertexColor = function(self) end,
 | 
						|
 | 
						|
	--- Gets whether the texture is desaturated.
 | 
						|
	--- @return boolean isDesaturated True if the texture is desaturated.
 | 
						|
	--- @example
 | 
						|
	--- local isDesaturated = myTexture:IsDesaturated()
 | 
						|
	IsDesaturated = function(self) end,
 | 
						|
 | 
						|
	--- Sets the blend mode of the texture.
 | 
						|
	--- @param mode string The blend mode ("DISABLE", "BLEND", "ALPHAKEY", "ADD", "MOD").
 | 
						|
	--- @example
 | 
						|
	--- myTexture:SetBlendMode("ADD")
 | 
						|
	SetBlendMode = function(self, mode) end,
 | 
						|
 | 
						|
	--- Sets whether the texture should be displayed without saturation.
 | 
						|
	--- @param desaturated boolean True to desaturate the texture.
 | 
						|
	--- @example
 | 
						|
	--- myTexture:SetDesaturated(true)
 | 
						|
	SetDesaturated = function(self, desaturated) end,
 | 
						|
 | 
						|
	--- Sets a color gradient across the texture.
 | 
						|
	--- @param orientation string The gradient orientation ("HORIZONTAL" or "VERTICAL").
 | 
						|
	--- @param startR number The start red value.
 | 
						|
	--- @param startG number The start green value.
 | 
						|
	--- @param startB number The start blue value.
 | 
						|
	--- @param endR number The end red value.
 | 
						|
	--- @param endG number The end green value.
 | 
						|
	--- @param endB number The end blue value.
 | 
						|
	--- @example
 | 
						|
	--- myTexture:SetGradient("HORIZONTAL", 1, 0, 0, 0, 0, 1)
 | 
						|
	SetGradient = function(self, orientation, startR, startG, startB, endR, endG, endB) end,
 | 
						|
 | 
						|
	--- Sets a color gradient with alpha across the texture.
 | 
						|
	--- @param orientation string The gradient orientation ("HORIZONTAL" or "VERTICAL").
 | 
						|
	--- @param startR number The start red value.
 | 
						|
	--- @param startG number The start green value.
 | 
						|
	--- @param startB number The start blue value.
 | 
						|
	--- @param startA number The start alpha value.
 | 
						|
	--- @param endR number The end red value.
 | 
						|
	--- @param endG number The end green value.
 | 
						|
	--- @param endB number The end blue value.
 | 
						|
	--- @param endA number The end alpha value.
 | 
						|
	--- @example
 | 
						|
	--- myTexture:SetGradientAlpha("VERTICAL", 1, 0, 0, 1, 0, 0, 1, 0)
 | 
						|
	SetGradientAlpha = function(self, orientation, startR, startG, startB, startA, endR, endG, endB, endA) end,
 | 
						|
 | 
						|
	--- Sets the texture's rotation.
 | 
						|
	--- @param angle number The rotation angle in radians.
 | 
						|
	--- @param cx number? Optional. The x coordinate of the rotation center.
 | 
						|
	--- @param cy number? Optional. The y coordinate of the rotation center.
 | 
						|
	--- @example
 | 
						|
	--- myTexture:SetRotation(math.pi / 2)
 | 
						|
	SetRotation = function(self, angle, cx, cy) end,
 | 
						|
 | 
						|
	--- Sets the texture coordinates.
 | 
						|
	--- @param left number The left coordinate.
 | 
						|
	--- @param right number The right coordinate.
 | 
						|
	--- @param top number The top coordinate.
 | 
						|
	--- @param bottom number The bottom coordinate.
 | 
						|
	--- @example
 | 
						|
	--- myTexture:SetTexCoord(0, 1, 0, 1)
 | 
						|
	SetTexCoord = function(self, left, right, top, bottom) end,
 | 
						|
 | 
						|
	--- Sets the texture to be displayed.
 | 
						|
	--- @param texture string|number The texture path or file ID.
 | 
						|
	--- @example
 | 
						|
	--- myTexture:SetTexture("Interface\\Icons\\Spell_Nature_Regeneration")
 | 
						|
	SetTexture = function(self, texture) end,
 | 
						|
 | 
						|
	--- Sets the texture to a solid color.
 | 
						|
	--- @param r number The red component.
 | 
						|
	--- @param g number The green component.
 | 
						|
	--- @param b number The blue component.
 | 
						|
	--- @param a number? Optional. The alpha component.
 | 
						|
	--- @example
 | 
						|
	--- myTexture:SetColorTexture(1, 0, 0, 1)
 | 
						|
	SetColorTexture = function(self, r, g, b, a) end,
 | 
						|
}
 |