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

◆ Narrow() [1/7]

static unsafe Vector< float > System.Numerics.Vector< T >.Narrow ( Vector< double > low,
Vector< double > high )
inlinestatic

Definition at line 722 of file Vector.cs.

723 {
724 int count = Vector<float>.Count;
725 float* ptr = stackalloc float[count];
726 for (int i = 0; i < count / 2; i++)
727 {
728 ptr[i] = (float)low[i];
729 }
730 for (int j = 0; j < count / 2; j++)
731 {
732 ptr[j + count / 2] = (float)high[j];
733 }
734 return *(Vector<float>*)ptr;
735 }

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