LUT-based image manipulations are global in the following sense: all pixels with the same value, regardless of their location in the image are mapped to a given new value. It is also 'context-free' in the sense that the mapping is independent of neighboring pixels' values. While LUT-based image manipulation is efficient, it has its limitations. For example, SEM images often have both very bright areas and very dark areas, and both may contain important details. LUT-based manipulation if often insufficient for easy perception of all details. In this paper we describe a method that was developed for the VeraSEM, Applied Material's new wafer metrology tool. THe method performs regional, rather than global contrast enhancement, while maintaining brightness relationship between regions. The method succeeds in bringing out much detail in regions of low and high brightness in the same image. However, since it is both local, and content sensitive, it is more expensive computationally than LUT-based manipulation. To obtain regional stretching, the image is divided into blocks, and the parameters for stretching are extracted separately per block. To avoid 'blockiness' of the final result, the parameter values are modified to provide a smooth transition between adjacent blocks. After this modification, each pixel has its own set of parameters, which are eventually used to compute its new value.