Applied floodfill algorithm and created a mask image of the plate region.