Beispiel #1
0
            private bool TryStartMergeJob(int divideIndex, int pendingThreshold)
            {
                bool jobStarted = false;
                var  meshId     = m_mergedLodMeshProxies[divideIndex].MeshId;
                var  workId     = m_runningWorkId + 1;

                if (MyCommon.FrameCounter >= m_mergeJobs[divideIndex].NextPossibleMergeStartTime &&
                    MyMeshes.TryStartMerge(meshId, m_parentClipmap.Id, pendingThreshold, m_mergeJobs[divideIndex].LodMeshesBeingMerged, workId))
                {
                    // Sent message
                    m_mergeJobs[divideIndex].CurrentWorkId = ++m_runningWorkId;
                    m_mergeJobs[divideIndex].NextPossibleMergeStartTime = MyCommon.FrameCounter + MergeJobInfo.MergeJobDelay;
                    jobStarted = true;
                }
                return(jobStarted);
            }