1. A method for processing image data comprising: detecting a gray level distribution of frame image data; calculating a cluster size of each of gray levels based on the gray level distribution; determining a remapping function for increasing contrast of the frame image data based on the gray level distribution and the cluster size; and converting the frame image data based on the remapping function.