The gluScaleImage function scales an image to an arbitrary size.
int gluScaleImage(
GLenum format,
GLint widthin,
GLint heightin,
GLenum typein,
const void * datain,
GLint widthout,
GLint heightout,
GLenum typeout,
void * dataout
);
If the function succeeds, the return value is zero.
If the function fails, the return value is a GLU error code (see gluErrorString).
The gluScaleImage function scales a pixel image using the appropriate pixel store modes to unpack data from the source image and pack data into the destination image.
When shrinking an image, gluScaleImage uses a box filter to sample the source image and create pixels for the destination image. When magnifying an image, the pixels from the source image are linearly interpolated to create the destination image.
For a description of the acceptable values for the format, typein, and typeout parameters, see glReadPixels.
Windows NT: Use version 3.5 and later.
Windows: Use Windows 95 and later.
Windows CE: Unsupported.
Header: Declared in glu.h.
Import Library: Link with glu32.lib.
glDrawPixels, glReadPixels, gluBuild1DMipmaps, gluBuild2DMipmaps, gluErrorString