2026-04-16 오브젝트 그림자

This commit is contained in:
skrwns304@gmail.com
2026-04-16 04:58:10 +09:00
parent 0fe8b18872
commit 42646a636f
303 changed files with 54374 additions and 20 deletions

View File

@@ -0,0 +1,24 @@
using System.Runtime.CompilerServices;
using Unity.Collections;
using Unity.Collections.LowLevel.Unsafe;
namespace BadDog.Rendering.AreaLight
{
internal static class NativeArrayExtensionsCompat
{
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static unsafe ref readonly T UnsafeElementAt<T>(this NativeArray<T> array, int index)
where T : struct
{
return ref UnsafeUtility.ArrayElementAsRef<T>(NativeArrayUnsafeUtility.GetUnsafeReadOnlyPtr(array), index);
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static unsafe ref T UnsafeElementAtMutable<T>(this NativeArray<T> array, int index)
where T : struct
{
return ref UnsafeUtility.ArrayElementAsRef<T>(NativeArrayUnsafeUtility.GetUnsafePtr(array), index);
}
}
}