magnify


Purpose:

This program will magnify images independently along the three major axes using Fourier interpolation. Magnification factors are restricted to values that can be expressed as the ratio of two integers, and the integer in the denominator must be a factor of the corresponding image dimension.


Usage:

magnify input output overwrite?(y/n) magnify-x magnify-y magnify-z [shrink-x shrink-y shrink-z]

where the following definitions apply:

input
The name of the input file.
output
The name of the output file
overwrite?(y/n)
The letter 'y' if you want to overwrite any preexisting file with the same name as you specified for the output.
magnify-x
The x magnification factor. This must be an integer greater than or equal to 1.
magnify-y
The y magnification factor. This must be an integer greater than or equal to 1.
magnify-z
The z magnification factor. This must be an integer greater than or equal to 1.
shrink-x
The optional x minification factor. This must be a positive integer and must be smaller than the x magnification factor (i.e., the net effect of the two factors cannot result in net minification). This value must also be a factor of the x dimension of the file.
shrink-y
The optional y minification factor. This must be a positive integer and must be smaller than the y magnification factor (i.e., the net effect of the two factors cannot result in net minification). This value must also be a factor of the y dimension of the file.
shrink-z
The optional z minification factor. This must be a positive integer and must be smaller than the z magnification factor (i.e., the net effect of the two factors cannot result in net minification). This value must also be a factor of the z dimension of the file.


Examples:

magnify mri bigmri y 2 2 1

magnify mri bigmri y 3 3 1 2 2 1


Comments:


Error messages: (alphabetical by case)

See also: Generic error messages

Magnifications must be integers greater than or equal to 1
  • Self explanatory.
Magnifications must be larger than shrinkages
  • You cannot have net minification.
Shrinkages must be integers greater than or equal to 1
  • Self explanatory.
x shrinkage should be a factor of the x dimension (____)
  • Respecify using a factor of the dimension (1 is also considered a factor).
y shrinkage should be a factor of the y dimension (____)
  • Respecify using a factor of the dimension (1 is also considered a factor).
z shrinkage should be a factor of the z dimension (____)
  • Respecify using a factor of the dimension (1 is also considered a factor).


See also:


Modified: December 11, 1996

© 1995-6 Roger P. Woods, M.D.(rwoods@ucla.edu)