1. An image processing apparatus comprising: an attribute determination unit that divides image data into a plurality of blocks each having a predetermined number of pixels and determines an attribute of each of the divided blocks that indicates whether or not the block includes a character; a connected area extraction unit that extracts a connected area in which pixels having the same pixel characteristic are connected sequentially, from each of the divided blocks; and a foreground/background determination unit that selects a foreground/background determination method to be used for a processing target block, based on the attribute of the processing target block, the attribute of a first adjacent block that is adjacent to the processing target block, and the extracted connected areas, and determines whether a connected area of the processing target block among the extracted connected areas is the foreground or the background, using the selected foreground/background determination method.