view resize-gd.1 @ 17:159402d54c29 default tip

replaced atoi with strtol, which is more secure
author meillo@marmaro.de
date Tue, 22 Jul 2008 10:07:27 +0200
parents c50716420346
children
line wrap: on
line source

.TH RESIZE\-GD 1 "resize\-gd\-0.2" "2008\-06\-15" "resize\-gd"

.SH NAME
resize\-gd \- resizes images using the gd library

.SH SYNOPSIS
.B resize\-gd <size> PICTURES

.B resize\-gd <width>x<height> PICTURES

.SH DESCRIPTION
The program resizes given images to a specific size. The files are modified, so copy the files before if you want to keep the original pictures!
.PP
If <size> is given, aspect ratio of the images is preserved and only shrinking is done. Smaller images remain unmodified.
.PP
If <width>x<height> ist given, the images are resized to match that dimensions. The images probably get stretched and enlarged.
.PP
Only JPEG and PNG files are supported. The filetype is detected by the filename suffix which has to be `.jpg', `.jpeg' or `.png'.
Unsupported files get skipped.
.PP
This program is meant to be a small(er) alternative to the
.BR mogrify \-resize
command of ImageMagick. Mainly because ImageMagick has lots of dependencies, while the GD\-Library has less.

.SH OPTIONS
.TP
.B \-\-help
Show summary of options.
.TP
.B \-\-version
Show program name and version.

.SH EXAMPLES
Create some thumbnails, preserving aspect ratio:
.IP
mkdir thumbs

cp *.jpg *.png thumbs

resize\-gd 150 thumbs/*

.PP
Make some pictures squared:
.IP
cp \-r somepics/ somepics\-squared

resize\-gd 400x400 somepics\-squared/*

.SH EXIT CODE
.TP
.B 1
Any other error
.TP
.B 2
The size (parameter 1) had no valid format. It has to be either <size> or <width>x<height>.
.TP
.B 3
Not enough memory available to resize the image.
.TP
.B 4
None of the given files was resized successful (or was already small enough).

.SH BUGS
Please report any bug you find to the author.

.SH SEE ALSO
.BR mogrify (1),
.BR ImageMagick (1).

.SH AUTHOR
resize\-gd and this man page were written by markus schnalke <meillo@marmaro.de>
.PP
Website: http://prog.marmaro.de/resize\-gd