3D Lingo Dictionary > T-Z > vertices |
![]() ![]() ![]() |
vertices
Syntax
member(whichCastmember
).modelResource(whichModelResource
).face[faceIndex
].vertices
Description
3D face property; when used with a mode resource whose type is #mesh
, this property allows you to get or set which vertices from the resource's vertexList (mesh deform)
to use for the mesh face specified by faceIndex
.
This property is a linear list of three integers corresponding to the index positions of the three vertices, as found in the mesh's vertexList
property, that comprise the specified face.
The vertices must be specified in the list using counterclockwise winding in order to achieve an outward pointing surface normal.
If you make changes to this property or use the generateNormals()
command, you will need to call the build()
command in order to rebuild the mesh.
Example
This example displays the vertexList
of the mesh model resource named SimpleSquare, then it displays the vertices
property for the second face of that mesh.
put member("3D").modelResource("SimpleSquare").vertexList -- [vector( 0.0000, 0.0000, 0.0000), vector( 0.0000, 5.0000, 0.0000), vector( 5.0000, 0.0000, 0.0000), vector( 5.0000, 5.0000, 0.0000)] put member("3D").modelResource("SimpleSquare").face[1].vertices -- [3, 4, 1]
See also
face
, vertexList (mesh deform)
, generateNormals()
![]() ![]() ![]() |