Exemplo n.º 1
0
        public static Bitmap GetGridFromScreeshot(Bitmap screenshot, GameMode gameMode)
        {
            var pos = GridLocator.LocateGrid(gameMode);

            return(Crop(screenshot, new Rectangle(pos.X, pos.Y, GridWidth, GridHeight)));
        }
Exemplo n.º 2
0
        public static Bitmap GetBlockFromScreenshot(Bitmap screenshot, GameMode gameMode, int coluna, int linha)
        {
            var pos = GridLocator.LocateGrid(gameMode);

            return(Crop(screenshot, new Rectangle(pos.X + (BlockWidth * coluna), pos.Y + (BlockHeight * linha), BlockWidth, BlockHeight)));
        }