FSO.Vitaboy.Mesh.StoreOnGPU C# (CSharp) Method

StoreOnGPU() public method

public StoreOnGPU ( GraphicsDevice device ) : void
device GraphicsDevice
return void
        public void StoreOnGPU(GraphicsDevice device)
        {
            GPUMode = true;
            GPUVertexBuffer = new DynamicVertexBuffer(device, typeof(VitaboyVertex), VertexBuffer.Length, BufferUsage.None);
            GPUVertexBuffer.SetData(VertexBuffer);

            GPUIndexBuffer = new IndexBuffer(device, IndexElementSize.SixteenBits, IndexBuffer.Length, BufferUsage.None);
            GPUIndexBuffer.SetData(IndexBuffer);
        }