 |
MeshUtilsGenerateCylindricalTextureCoordinates(PositionNormalTextureVertex, Int32, Vector3, Vector3) Method |
Generate texture coordinates for the given vertices and triangleIndices.
Texture coordinates are computed using cylindrical projection.
Texture coordinates for positions that are parallel to the cylinderDirectionVector use simple planar projection.
Texture coordinates for other positions are computed based on the angle from the cylinder center axis to the position.
Namespace: Ab4d.SharpEngine.UtilitiesAssembly: Ab4d.SharpEngine (in Ab4d.SharpEngine.dll) Version: 3.1.9316+94bbd23b55747f096f056a5602f7dd90558b3673
Syntaxpublic static Vector2[] GenerateCylindricalTextureCoordinates(
PositionNormalTextureVertex[] vertices,
int[] triangleIndices,
Vector3 cylinderDirectionVector,
Vector3 cylinderPlaneHeightVector
)
Parameters
- vertices PositionNormalTextureVertex
- Array of vertex data that defines the mesh.
- triangleIndices Int32
- Array of triangle indices that define the mesh.
- cylinderDirectionVector Vector3
- Direction vector of the cylinder (its upright / 3D height direction).
- cylinderPlaneHeightVector Vector3
- Direction vector along the cylinder's top and bottom planes (the 2D height direction of the 2D circle plane).
Return Value
Vector2Array of generated texture coordinates.
Remarks[Missing <remarks> documentation for "M:Ab4d.SharpEngine.Utilities.MeshUtils.GenerateCylindricalTextureCoordinates(Ab4d.SharpEngine.Common.PositionNormalTextureVertex[],System.Int32[],System.Numerics.Vector3,System.Numerics.Vector3)"]
See Also