public void Execute() { Result[0] = HashableShapeInputs.GetHash128( ForceUniqueIdentifier, GenerationParameters, Material, CollisionFilter, BakeFromShape, Inputs, AllSkinIndices, AllBlendShapeWeights ); }
static Hash128 GetHash128_FromMesh( UnityMesh mesh, float4x4 leafToBody, ConvexHullGenerationParameters convexHullGenerationParameters = default, Material material = default, CollisionFilter filter = default, float4x4 shapeFromBody = default, uint uniqueIdentifier = default, int[] includedIndices = default, float[] blendShapeWeights = default ) { // BUG: use TempJob to avoid InvalidOperationException triggered by NativeList.AddRange() inside SpookyHashBuilder using (var allIncludedIndices = new NativeList <int>(0, Allocator.TempJob)) using (var allBlendShapeWeights = new NativeList <float>(0, Allocator.TempJob)) using (var indices = new NativeArray <int>(includedIndices ?? Array.Empty <int>(), Allocator.TempJob)) using (var blendWeights = new NativeArray <float>(blendShapeWeights ?? Array.Empty <float>(), Allocator.TempJob)) return(HashableShapeInputs.GetHash128( uniqueIdentifier, convexHullGenerationParameters, material, filter, shapeFromBody, new NativeArray <HashableShapeInputs>(1, Allocator.Temp) { [0] = HashableShapeInputs.FromSkinnedMesh( mesh, leafToBody, indices, allIncludedIndices, blendWeights, allBlendShapeWeights ) }, allIncludedIndices, allBlendShapeWeights )); }