Double the number of rows and columns in an image file

**IMAGE_DOUBLE**
is a MATLAB program which
modifies an image file by doubling the number of rows and columns.
When displayed, this should result in an image that appears twice
as wide and high, with 4 times as many pixels.

In general, a better way to get a bigger picture is simply to use the original file, but increase the display size by stretching or rescaling. Here, we just want a simple way to make an image that will ``automatically'' display itself with doubled dimensions.

This doubling procedure may be repeated. The function image_decimate() will reverse the doubling operation.

The computer code and data files described and made available on this web page are distributed under the GNU LGPL license.

**IMAGE_DOUBLE** is available in
a MATLAB version.

IMAGE_COMPONENTS, a MATLAB library which seeks the connected "nonzero" or "nonblack" components of an image or integer vector, array or 3D block.

IMAGE_CONTRAST, a MATLAB program which applies image processing techniques to increase the contrast in an image.

IMAGE_DECIMATE, a MATLAB library which ``compresses'' a file by deleting the even rows and columns.

IMAGE_DENOISE, a MATLAB library which applies image processing techniques to remove noise from an image.

IMAGE_DENOISE_SPMD, a MATLAB program which demonstrates the SPMD parallel programming feature for image operations; the client reads an image, the workers process portions of it, and the client assembles and displays the results.

IMAGE_DIFFUSE, a MATLAB library which uses diffusion to smooth out an image.

IMAGE_EDGE, a MATLAB library which demonstrates a simple procedure for edge detection in images.

IMAGE_MATCH_GENETIC, a MATLAB program which tries to match a 256x256 JPEG image by blending 32 colored rectangles, using ideas from genetic algorithms, based on an example by Nick Berry.

IMAGE_NOISE, MATLAB programs which add noise to an image.

IMAGE_QUANTIZATION, a MATLAB library 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, MATLAB programs which makes a grayscale version of an RGB image.

IMAGE_THRESHOLD, MATLAB programs which make a black and white version of a grayscale image by setting all pixels below or above a threshold value to black or white.

- image_double_gray.m, decimates a grayscale image.
- timestamp.m, prints the YMDHMS date as a timestamp.

- image_double_test.m, calls all the tests.
- image_double_gray_test.m, tests image_double_gray().
- image_double_test_output.txt, the output file.

**casablanca8** is a grayscale image from a movie, which has been
decimated (cut in half) 3 times. As an amusing indication of software idiocy,
ImageMagick's convert() program is unable to handle the ASCII PGM files
output by Matlab...because there is no final carriage return! Software
failure caused by one missing carriage return! Maybe next century we'll
get it right.

- casablanca8.pgm, the decimated image.
- casablanca8.png
- casablanca8x2.pgm, the image after 1 doubling.
- casablanca8x2.png
- casablanca8x4.pgm, the image after 2 doublings.
- casablanca8x4.png
- casablanca8x8.pgm, the image after 3 doublings (back to original size, but missing 7/8 of its original data.)
- casablanca8x8.png

You can go up one level to the MATLAB source codes.