예제 #1
0
        public static unsafe void ResetRuntimeData(this INodeBlob blob, int index, int count = 1)
        {
            var dest = (void *)blob.GetRuntimeDataPtr(index);
            var src  = (void *)blob.GetDefaultDataPtr(index);

            UnsafeUtility.MemCpy(dest, src, blob.GetNodeDataSize(index, count));
        }
예제 #2
0
 public static unsafe ref T GetNodeDefaultData <T>(this INodeBlob blob, int index) where T : struct
 {
     return(ref UnsafeUtilityEx.AsRef <T>((void *)blob.GetDefaultDataPtr(index)));
 }