mirror of
https://github.com/vrm-c/UniVRM.git
synced 2026-08-16 07:38:25 -05:00
FastSpringBone作り直しのため、データ構造を再構築
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
using Unity.Burst;
|
||||
using Unity.Collections;
|
||||
using UnityEngine.Jobs;
|
||||
using UniVRM10.FastSpringBones.Blittables;
|
||||
|
||||
namespace UniVRM10.FastSpringBones.System
|
||||
{
|
||||
[BurstCompile]
|
||||
public struct PullTransformJob : IJobParallelForTransform
|
||||
{
|
||||
[WriteOnly] public NativeArray<BlittableTransform> Transforms;
|
||||
|
||||
public void Execute(int index, TransformAccess transform)
|
||||
{
|
||||
Transforms[index] = new BlittableTransform
|
||||
{
|
||||
Position = transform.position,
|
||||
Rotation = transform.rotation,
|
||||
LocalPosition = transform.localPosition,
|
||||
LocalRotation = transform.localRotation,
|
||||
LocalScale = transform.localScale,
|
||||
LocalToWorldMatrix = transform.localToWorldMatrix,
|
||||
WorldToLocalMatrix = transform.worldToLocalMatrix
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user