image_contrast


image_contrast, an Octave code which carries out a simple contrast enhancement operation on an image.

MATLAB's image processing toolbox includes functions such as nlfilter() which can do a more sophisticated treatment of images. But the purpose of this example is to demonstrate the process of image enhancement in a way that is clear enough to understand quickly.

For a gray-scale image, the function has the form:

function gray_enhanced = contrast_gray ( gray, s )
where

The corresponding function contrast_rgb() operates on RGB images.

Licensing:

The information on this web page is distributed under the MIT license.

Languages:

image_contrast is available in a MATLAB version and an Octave version.

Related Data and Programs:

image_contrast_test

image_boundary, an Octave code which reports the pixels which form the boundary between the black and white regions of a simple image.

image_components, an Octave code which seeks the connected "nonzero" or "nonblack" components of an image or integer vector, array or 3D block.

image_decimate, an Octave code which compresses an image by dropping the even rows and columns of data.

image_denoise, an Octave code which demonstrates a simple technique for removing noise from an image.

image_double, an Octave code which doubles the height and width of an image by repeating each row and column.

image_edge an Octave code which demonstrates a simple procedure for edge detection in images.

image_noise, an Octave code which adds noise to an image.

image_quantization, an Octave code which demonstrates how the KMEANS algorithm can be used to reduce the number of colors or shades of gray in an image.

image_rgb_to_gray, an Octave code which makes a grayscale version of an RGB image.

image_threshold, an Octave code which makes a black and white version of a grayscale image by setting all pixels below or above a threshold value to black or white.

Reference:

Source Code:


Last revised on 04 August 2024.