private void Start() { CreateMatrices(); SpawnBoids(); parallelAddToDictFunc = ParallelAddToDict; parallelSteeringFunc = ParallelSteering; ConcurrencyLevel = SystemInfo.processorCount; boidsDictConcurrent = new ConcurrentDictOfLists <Boid>(ConcurrencyLevel); parallelOpts.MaxDegreeOfParallelism = ConcurrencyLevel; Debug.Log("System has " + SystemInfo.processorCount + " hardware threads, setting concurrency level..."); }
private void Start() { CreateMatrices(); SpawnBoids(); parallelAddToDictFunc = ParallelAddToDict; parallelSteeringFunc = ParallelSteering; ConcurrencyLevel = SystemInfo.processorCount; boidsDictConcurrent = new ConcurrentDictOfLists <Boid>(ConcurrencyLevel); parallelOpts.MaxDegreeOfParallelism = ConcurrencyLevel; Debug.Log("System has " + SystemInfo.processorCount + " hardware threads, setting concurrency level..."); guiStyle = new GUIStyle(); guiStyle.fontSize = 27; guiStyle.normal.textColor = Color.white; boidsSampler = CustomSampler.Create("BoidsSimulation"); }