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

◆ InitializeDeviceState()

void Microsoft.Xna.Framework.Graphics.SamplerStateCollection.InitializeDeviceState ( )
inlinepackage

Definition at line 58 of file SamplerStateCollection.cs.

59 {
60 int num = 0;
61 SamplerState[] array = pSamplerList;
62 if (0 >= (nint)array.LongLength)
63 {
64 return;
65 }
66 while (true)
67 {
68 array[num] = null;
69 SamplerState linearWrap = SamplerState.LinearWrap;
70 if (num < 0)
71 {
72 break;
73 }
75 if (num >= (nint)array.LongLength)
76 {
77 break;
78 }
79 if (linearWrap != null)
80 {
81 if (linearWrap != array[num])
82 {
83 linearWrap.Apply(pDevice, samplerOffset + num);
84 pSamplerList[num] = linearWrap;
85 }
86 num++;
88 if (num >= (nint)array.LongLength)
89 {
90 return;
91 }
92 continue;
93 }
94 throw new ArgumentNullException("value", FrameworkResources.NullNotAllowed);
95 }
96 throw new ArgumentOutOfRangeException("index");
97 }
unsafe void Apply(GraphicsDevice device, int samplerIndex)
static readonly SamplerState LinearWrap

References Microsoft.Xna.Framework.Graphics.SamplerState.Apply(), System.array, Microsoft.Xna.Framework.Graphics.SamplerState.LinearWrap, Microsoft.Xna.Framework.FrameworkResources.NullNotAllowed, Microsoft.Xna.Framework.Graphics.SamplerStateCollection.pDevice, Microsoft.Xna.Framework.Graphics.SamplerStateCollection.pSamplerList, and Microsoft.Xna.Framework.Graphics.SamplerStateCollection.samplerOffset.

Referenced by Microsoft.Xna.Framework.Graphics.GraphicsDevice.InitializeDeviceState().