Version: Unity 6.4 Alpha (6000.4)
LanguageEnglish
  • C#

XRMeshSubsystem.TryGetSubmeshClassifications(MeshId, Allocator, out uint, out NativeArray<uint>, out NativeArray<uint>)

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Parameters

Parameter Description
id A MeshId obtained earlier through TryGetMeshInfos for which to retrieve classification information
allocator The Allocator type to use for the returned NativeArrays
elementsPerVector The number of packed elements in vertexIndexVectors to treat as one classification unit. Platform-specific; for example, some platforms may use `1` for a single vertex per classification; others may use `3` to represent a triangle face per classification.
vertexIndexVectors The indices referring to Mesh vertices that the classifications apply to, coallated with classifications.
classifications The opaque classification enumerations returned by the provider for the defined vertex components above.

Returns

void True if the retrieval is successful, otherwise False

Description

Gets classification information for vertices or vertex sets for meshes obtained through XRMeshSubsystem.TryGetMeshInfos. This must be enabled through XRMeshSubsystem._submeshClassificationEnabled.

Use this to retrieve semantic classifications for vertex or vertex group components of the meshes tracked by the subsystem.

This method always returns new NativeArrays, even when there are no results. The caller is responsible for disposing the returned NativeArray, though specifying the appropriate Allocator will manage this for you.

Additional resources: XRMeshSubsystem._submeshClassificationEnabled, XRMeshSubsystem.TryGetMeshInfos

Copyright © 2023 Unity Technologies
优美缔软件(上海)有限公司 版权所有
"Unity"、Unity 徽标及其他 Unity 商标是 Unity Technologies 或其附属机构在美国及其他地区的商标或注册商标。其他名称或品牌是其各自所有者的商标。
公安部备案号:
31010902002961