Esempio n. 1
0
 private void doFileWriteJob()
 {
     if (logTextAdded == 1)
     {
         // schedule the file write job
         LogToFile jobData = new LogToFile();
         jobData.logStr = new NativeArray <byte>(mainLogText.Length, Allocator.Temp);
         jobData.logStr.CopyFrom(Encoding.ASCII.GetBytes(mainLogText.ToString()));
         JobHandle handle = jobData.Schedule();
         handle.Complete();
         jobData.logStr.Dispose();
         logTextAdded = 0;
     }
 }