void ResetGraphicsBuffer(int nodeSize) { ConsumeNodeList.SetCounterValue(0); AppendNodeList.SetCounterValue(0); AppendFinalNodeList.SetCounterValue(0); QuadTreeNode[] nodes = new QuadTreeNode[nodeSize * nodeSize]; int index = 0; for (int i = 0; i < nodeSize; ++i) { for (int j = 0; j < nodeSize; ++j) { nodes[index].x = (uint)j; nodes[index].y = (uint)i; ++index; } } ConsumeNodeList.SetData(nodes); ConsumeNodeList.SetCounterValue((uint)nodes.Length); }