예제 #1
0
        public void DrawImage(IBlit blit, int x, int y, int srcx, int srcy,
                              int srcwidth, int srcheight)
        {
            var fast         = blit as BlitFast;
            var internalBlit = fast ?? new BlitFast(blit.GetBitmap());

            Lock();
            if (internalBlit._canBeTransparent)
            {
                InternalDrawImageAlpha(internalBlit, x, y, srcx, srcy, srcwidth, srcheight);
            }
            else
            {
                InternalDrawImage(internalBlit, x, y, srcx, srcy, srcwidth, srcheight);
            }
        }
예제 #2
0
        public void DrawImage(IBlit blit, int x, int y, Rectangle srcrect)
        {
            var image = blit.GetBitmap();

            _graphics.DrawImage(image, x, y, srcrect, GraphicsUnit.Pixel);
        }