ClothMeshResource
A mesh resource that defines the topology and shape of a cloth body or a mesh-shaped cloth collider.
Declaration
final class ClothMeshResourceOverview
Topics
Creating a cloth mesh
init(positions:triangleIndices:)patch(size:targetEdgeLength:)box(size:targetEdgeLength:)sphere(radius:targetEdgeLength:)capsule(height:radius:targetEdgeLength:)cylinder(height:radius:withCaps:targetEdgeLength:)defaultTargetEdgeLength
Accessing vertex data
vertexCountpositionsposition(at:)withPositions(_:)vertexIndex(at:)vertexIndex(primitive:vertex:)vertices(in:center:orientation:)