예제 #1
0
 /// <summary>
 /// Destroy this texture instance.
 /// </summary>
 public void Destroy()
 {
     if (_ceTex != null && _texId != 0)
     {
         var id = _texId;
         GameFramework.AddDestroyAction(() => DestroyNativeTexture(id));
         _ceTex.Dispose();
         _ceTex = null;
         _texId = 0;
     }
 }
예제 #2
0
 /// <summary>
 /// Destroy this texture instance.
 /// </summary>
 public void Destroy()
 {
     if (_nativeTexture != null && _texId != 0)
     {
         var id             = _texId;
         var isRenderTarget = _isRenderTarget;
         GameFramework.AddDestroyAction(() => DestroyNativeTexture(id, isRenderTarget));
         _nativeTexture.Dispose();
         _nativeTexture = null;
         _texId         = 0;
     }
 }