Difference between revisions of "Mesh:setVertex"
(Geometry:setVertex -> Mesh:setVertex) |
|||
Line 1: | Line 1: | ||
{{newin|[[0.9.0]]|090|type=function}} | {{newin|[[0.9.0]]|090|type=function}} | ||
Sets the properties of a vertex in the Mesh. | Sets the properties of a vertex in the Mesh. | ||
− | |||
== Function == | == Function == | ||
=== Synopsis === | === Synopsis === | ||
Line 13: | Line 12: | ||
{{param|number|u|The horizontal component of the texture coordinate.}} | {{param|number|u|The horizontal component of the texture coordinate.}} | ||
{{param|number|v|The vertical component of the texture coordinate.}} | {{param|number|v|The vertical component of the texture coordinate.}} | ||
− | {{param|number|r|The red component of the vertex's color.}} | + | {{param|number|r (255)|The red component of the vertex's color.}} |
− | {{param|number|g|The green component of the vertex's color.}} | + | {{param|number|g (255)|The green component of the vertex's color.}} |
− | {{param|number|b|The blue component of the vertex's color.}} | + | {{param|number|b (255)|The blue component of the vertex's color.}} |
− | {{param|number|a|The alpha component of the vertex's color.}} | + | {{param|number|a (255)|The alpha component of the vertex's color.}} |
+ | === Returns === | ||
+ | Nothing. | ||
+ | == Function == | ||
+ | === Synopsis === | ||
+ | <source lang="lua"> | ||
+ | Mesh:setVertex( index, vertex ) | ||
+ | </source> | ||
+ | === Arguments === | ||
+ | {{param|number|index|The index of the the vertex you want to modify.}} | ||
+ | {{param|table|vertex|A table with vertex information.}} | ||
+ | {{subparam|number|[1]|The position of the vertex on the x-axis.}} | ||
+ | {{subparam|number|[2]|The position of the vertex on the y-axis.}} | ||
+ | {{subparam|number|[3]|The u texture coordinate. Texture coordinates are normally in the range of [0, 1], but can be greater or less (see [[WrapMode]].)}} | ||
+ | {{subparam|number|[4]|The v texture coordinate. Texture coordinates are normally in the range of [0, 1], but can be greater or less (see [[WrapMode]].)}} | ||
+ | {{subparam|number|[5] (255)|The red color component.}} | ||
+ | {{subparam|number|[6] (255)|The green color component.}} | ||
+ | {{subparam|number|[7] (255)|The blue color component.}} | ||
+ | {{subparam|number|[8] (255)|The alpha color component.}} | ||
=== Returns === | === Returns === | ||
Nothing. | Nothing. |
Revision as of 04:29, 23 October 2013
Available since LÖVE 0.9.0 |
This function is not supported in earlier versions. |
Sets the properties of a vertex in the Mesh.
Contents
Function
Synopsis
Mesh:setVertex( index, x, y, u, v, r, g, b, a )
Arguments
number index
- The index of the the vertex you want to modify.
number x
- The position of the vertex (x-axis).
number y
- The position of the vertex (y-axis).
number u
- The horizontal component of the texture coordinate.
number v
- The vertical component of the texture coordinate.
number r (255)
- The red component of the vertex's color.
number g (255)
- The green component of the vertex's color.
number b (255)
- The blue component of the vertex's color.
number a (255)
- The alpha component of the vertex's color.
Returns
Nothing.
Function
Synopsis
Mesh:setVertex( index, vertex )
Arguments
number index
- The index of the the vertex you want to modify.
table vertex
- A table with vertex information.
number [1]
- The position of the vertex on the x-axis.
number [2]
- The position of the vertex on the y-axis.
number [3]
- The u texture coordinate. Texture coordinates are normally in the range of [0, 1], but can be greater or less (see WrapMode.)
number [4]
- The v texture coordinate. Texture coordinates are normally in the range of [0, 1], but can be greater or less (see WrapMode.)
number [5] (255)
- The red color component.
number [6] (255)
- The green color component.
number [7] (255)
- The blue color component.
number [8] (255)
- The alpha color component.
Returns
Nothing.
See Also
Other Languages
Dansk –
Deutsch –
English –
Español –
Français –
Indonesia –
Italiano –
Lietuviškai –
Magyar –
Nederlands –
Polski –
Português –
Română –
Slovenský –
Suomi –
Svenska –
Türkçe –
Česky –
Ελληνικά –
Български –
Русский –
Српски –
Українська –
עברית –
ไทย –
日本語 –
正體中文 –
简体中文 –
Tiếng Việt –
한국어
More info