예제 #1
0
            internal unsafe static void RequestLights(Light[] lights, System.IntPtr outLightsPtr, int outLightsCount, AtomicSafetyHandle safetyHandle)
            {
                var outLights = NativeArrayUnsafeUtility.ConvertExistingDataToNativeArray <LightDataGI>((void *)outLightsPtr, outLightsCount, Allocator.None);

                NativeArrayUnsafeUtility.SetAtomicSafetyHandle(ref outLights, safetyHandle);
                s_RequestLightsDelegate(lights, outLights);
            }
 public void Add <T>(NativeArray <T> value) where T : struct
 {
     Add(value.Length);
     Add(NativeArrayUnsafeUtility.GetUnsafeReadOnlyPtr(value), UnsafeUtility.SizeOf <T>() * value.Length);
 }