void ReleaseStudioSystem()
 {
     if (studioSystem.isValid())
     {
         studioSystem.release();
         studioSystem.clearHandle();
     }
 }
Esempio n. 2
0
 void CheckInitResult(FMOD.RESULT result, string cause)
 {
     if (result != FMOD.RESULT.OK)
     {
         if (studioSystem.isValid())
         {
             studioSystem.release();
             studioSystem.clearHandle();
         }
         throw new SystemNotInitializedException(result, cause);
     }
 }
Esempio n. 3
0
 void CheckInitResult(FMOD.RESULT result, string cause)
 {
     if (result != FMOD.RESULT.OK)
     {
         if (studioSystem != null)
         {
             studioSystem.release();
             studioSystem = null;
         }
         throw new SystemNotInitializedException(result, cause);
     }
 }
Esempio n. 4
0
 static void DestroySystem()
 {
     if (system.isValid())
     {
         system.release();
         system.clearHandle();
     }
 }
Esempio n. 5
0
 static void DestroySystem()
 {
     if (system != null)
     {
         UnityEngine.Debug.Log("FMOD Studio: Destroying editor system instance");
         system.release();
         system = null;
     }
 }
Esempio n. 6
0
 static void DestroySystem()
 {
     if (system.isValid())
     {
         UnityEngine.Debug.Log("FMOD Studio: Destroying editor system instance");
         system.release();
         system.clearHandle();
     }
 }
Esempio n. 7
0
        private bool disposedValue = false; // To detect redundant calls

        protected virtual void Dispose(bool disposing)
        {
            if (!disposedValue)
            {
                Console.WriteLine("FMODSystem: Disposing");

                if (disposing)
                {
                    // TODO: dispose managed state (managed objects).
                    instance = null;
                }

                _system.release();
                // TODO: free unmanaged resources (unmanaged objects) and override a finalizer below.


                // TODO: set large fields to null.

                disposedValue = true;
            }
        }