1. A method of coding an image, the method comprising: determining an image format and a coding mode of each of regions of the image; determining whether a current image format of a first region from among the regions of the image is to be switched, based on the determined image format; and coding the first region, based on the determined image format and coding mode.