Difference between revisions of "Mesh:setTextureCoordinates"

From GiderosMobile
(clarification?)
m (Text replacement - "<source" to "<syntaxhighlight")
Line 5: Line 5:
 
=== Description ===
 
=== Description ===
 
Sets zero or more texture coordinates with a single function call.
 
Sets zero or more texture coordinates with a single function call.
<source lang="lua">
+
<syntaxhighlight lang="lua">
 
Mesh:setTextureCoordinates(textureCoordinates)
 
Mesh:setTextureCoordinates(textureCoordinates)
 
</source>
 
</source>
Line 14: Line 14:
 
=== Examples ===
 
=== Examples ===
 
'''Texture coordinates function calls'''
 
'''Texture coordinates function calls'''
<source lang="lua">
+
<syntaxhighlight lang="lua">
 
-- sets 3 texture coordinates with seperate function calls
 
-- sets 3 texture coordinates with seperate function calls
 
mesh:setTextureCoordinate(1, 0, 0)
 
mesh:setTextureCoordinate(1, 0, 0)

Revision as of 15:28, 13 July 2023

Available since: Gideros 2012.09
Class: Mesh

Description

Sets zero or more texture coordinates with a single function call. <syntaxhighlight lang="lua"> Mesh:setTextureCoordinates(textureCoordinates) </source>

Parameters

textureCoordinates: (any) multiple values or a Lua array

Examples

Texture coordinates function calls <syntaxhighlight lang="lua"> -- sets 3 texture coordinates with seperate function calls mesh:setTextureCoordinate(1, 0, 0) mesh:setTextureCoordinate(2, 100, 0) mesh:setTextureCoordinate(3, 0, 100)

-- sets 3 texture coordinates with one function call mesh:setTextureCoordinates(1, 0, 0, 2, 100, 0, 3, 0, 100)

-- same as above mesh:setTextureCoordinates{1, 0, 0, 2, 100, 0, 3, 0, 100}

-- these two functions do nothing mesh:setTextureCoordinates() mesh:setTextureCoordinates{} </source>