Пример #1
0
 public void Dispose()
 {
     _atlasItems.Clear();
     if (MainBitmap != null && IsMemBitmapOwner)
     {
         MainBitmap.Dispose();
         MainBitmap = null;
     }
 }
Пример #2
0
        public void SetMainBitmap(MemBitmap mainBmp, bool isOwner)
        {
            if (MainBitmap != null && MainBitmap != mainBmp && IsMemBitmapOwner)
            {
                //dispose current main bmp
                MainBitmap.Dispose();
                MainBitmap       = null;
                IsMemBitmapOwner = false;
            }

            MainBitmap       = mainBmp;
            IsMemBitmapOwner = isOwner;
        }