Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ Widen() [4/7]

static unsafe void System.Numerics.Vector< T >.Widen ( Vector< sbyte > source,
out Vector< short > low,
out Vector< short > high )
inlinestatic

Definition at line 550 of file Vector.cs.

551 {
552 int count = Vector<sbyte>.Count;
553 short* ptr = stackalloc short[count / 2];
554 for (int i = 0; i < count / 2; i++)
555 {
556 ptr[i] = source[i];
557 }
558 short* ptr2 = stackalloc short[count / 2];
559 for (int j = 0; j < count / 2; j++)
560 {
561 ptr2[j] = source[j + count / 2];
562 }
563 low = *(Vector<short>*)ptr;
564 high = *(Vector<short>*)ptr2;
565 }

References System.count, System.Numerics.Vector< T >.Count, and System.source.