コード例 #1
0
        static void ResizeStorage()
        {
            int size = m_sortedBuffer.Length;

            while (BillboardCount > size)
            {
                size *= 2;
            }
            Array.Resize(ref m_sortedBuffer, size);

            size = m_arrayDataBillboards.Length;
            while (BillboardCountSafe > size)
            {
                size *= 2;
            }
            m_arrayDataBillboards.Resize(size);

            size = m_arrayDataWindows.Length;
            while (WindowCountSafe > size)
            {
                size *= 2;
            }
            m_arrayDataWindows.Resize(size);
            Array.Resize(ref m_sorteWindowIndices, size);
        }
コード例 #2
0
        private static void InitGatherList(int count, int countSafe)
        {
            int size = m_tempBuffer.Length;

            while (count > size)
            {
                size *= 2;
            }
            Array.Resize(ref m_tempBuffer, size);

            size = m_arrayDataBillboards.Length;
            while (countSafe > size)
            {
                size *= 2;
            }
            m_arrayDataBillboards.Resize(size);

            for (int i = 0; i < BUCKETS_COUNT; i++)
            {
                m_bucketBatches[i] = new MyBucketBatches();
            }

            m_lastBatchOffset = 0;
        }