1. A method for enhancing contrast in an image by mapping an input intensity value to an output intensity value in accordance with a mapping function, said method comprising the steps of: (a) determining a mean intensity value of said image; (b) calculating co-ordinates of said mapping function in accordance with said mean intensity value and a plurality of predefined parameters; and (c) applying said mapping function to said input intensity value for determining said output intensity; wherein said mapping function is generated dynamically for each image.