Skip to content

Commit eddf583

Browse files
Fix crash in il2cpp build (#67)
Co-authored-by: Paulm-Unity <[email protected]>
1 parent a88a065 commit eddf583

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

com.unity.render-pipelines.high-definition/Runtime/Lighting/ProbeVolume/DynamicGI/ProbeVolumeDynamicGI.cs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -959,7 +959,7 @@ unsafe void PrecomputeAxisCacheLookup(int axisAmount, BasisFunction basisFunctio
959959

960960
fixed (NeighborAxisLookup* sortedAxisPtr = &_sortedNeighborAxisLookups[sortedAxisStart])
961961
{
962-
CoreUnsafeUtils.QuickSort<NeighborAxisLookup>(s_NeighborAxis.Length, sortedAxisPtr);
962+
CoreUnsafeUtils.QuickSort<NeighborAxisLookup, NeighborAxisLookup, NeighborAxisLookup.NeighborAxisLookupKeyGetter>(s_NeighborAxis.Length, sortedAxisPtr);
963963
}
964964

965965
// Renormalize so all weights still add up to 1 when using limited axis amount.
@@ -1126,6 +1126,11 @@ public int CompareTo(NeighborAxisLookup other)
11261126
float diff = propagationWeight - other.propagationWeight;
11271127
return diff < 0 ? 1 : diff > 0 ? -1 : 0;
11281128
}
1129+
1130+
public struct NeighborAxisLookupKeyGetter : CoreUnsafeUtils.IKeyGetter<NeighborAxisLookup, NeighborAxisLookup>
1131+
{
1132+
public NeighborAxisLookup Get(ref NeighborAxisLookup v) { return v; }
1133+
}
11291134
}
11301135
}
11311136

0 commit comments

Comments
 (0)