Edit

Share via


MDLMesh.CreateCapsule Method

Definition

Overloads

CreateCapsule(Vector3, Vector2i, MDLGeometryType, Boolean, Int32, IMDLMeshBufferAllocator)
CreateCapsule(Single, Vector2, nuint, nuint, nuint, MDLGeometryType, Boolean, IMDLMeshBufferAllocator)

Creates a capsule from the width, height, and depth that are contained in dimensions, with the specified number of segments and geometry kind.

CreateCapsule(Vector3, Vector2i, MDLGeometryType, Boolean, Int32, IMDLMeshBufferAllocator)

[ObjCRuntime.TV(10, 0)]
public static ModelIO.MDLMesh CreateCapsule (OpenTK.Vector3 dimensions, OpenTK.Vector2i segments, ModelIO.MDLGeometryType geometryType, bool inwardNormals, int hemisphereSegments, ModelIO.IMDLMeshBufferAllocator allocator);
static member CreateCapsule : OpenTK.Vector3 * OpenTK.Vector2i * ModelIO.MDLGeometryType * bool * int * ModelIO.IMDLMeshBufferAllocator -> ModelIO.MDLMesh

Parameters

dimensions
Vector3
segments
Vector2i
geometryType
MDLGeometryType
inwardNormals
Boolean
hemisphereSegments
Int32

Returns

Attributes

Applies to

CreateCapsule(Single, Vector2, nuint, nuint, nuint, MDLGeometryType, Boolean, IMDLMeshBufferAllocator)

Creates a capsule from the width, height, and depth that are contained in dimensions, with the specified number of segments and geometry kind.

[Foundation.Export("newCapsuleWithHeight:radii:radialSegments:verticalSegments:hemisphereSegments:geometryType:inwardNormals:allocator:")]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 10, 2, ObjCRuntime.PlatformArchitecture.All, null)]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.MacOSX, 10, 12, 2, ObjCRuntime.PlatformArchitecture.All, null)]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.TvOS, 10, 1, ObjCRuntime.PlatformArchitecture.All, null)]
public static ModelIO.MDLMesh CreateCapsule (float height, OpenTK.Vector2 radii, nuint radialSegments, nuint verticalSegments, nuint hemisphereSegments, ModelIO.MDLGeometryType geometryType, bool inwardNormals, ModelIO.IMDLMeshBufferAllocator allocator);
static member CreateCapsule : single * OpenTK.Vector2 * nuint * nuint * nuint * ModelIO.MDLGeometryType * bool * ModelIO.IMDLMeshBufferAllocator -> ModelIO.MDLMesh

Parameters

height
Single

The height of the capsule.

radii
Vector2

The radii of the capsule.

radialSegments
System.System.UIntPtr System.unativeint

The number of radial segments to generate.

verticalSegments
System.System.UIntPtr System.unativeint

The number of vertical segments to generate in the cylinder.

hemisphereSegments
System.System.UIntPtr System.unativeint

The number segments to generate in the caps.

geometryType
MDLGeometryType

Whether to create triangles, quadrilaterals, or lines.

inwardNormals
Boolean

Whether to generate inward-pointing normals.

allocator
IMDLMeshBufferAllocator

The allocator to use instead of the default, internal allocator.

This parameter can be null.

Returns

Attributes

Applies to