Use the ScaleDIB function or method from BiDIB DLL or OCX for resizing an image. There is a bilinear and a cubic spline method for scaling.
[C++]
/* Scaling an image */
#include “BiDIB.h”
HDIB hDibNew;
XYSIZE xySize;
xySize.x = 100;
xySize.y = 100;
/* 1. parameter: Handle of the DIB to scale
2. parameter: Method (0 - bilinear 1 - cubic spline
3. parameter: Size of the output DIB */
hDibNew = ScaleDIB(hDib, 0, xySize);
if (!hDibNew)
{
// Error
}
[C#]
/* Scaling an image */
long hDibNew;
/* 1. parameter: Handle of the DIB to scale
2. parameter: Method (0 - bilinear 1 - cubic spline
3. parameter: Size of the output DIB */
hDibNew = BiDIB.ScaleDIB(hDib, 0, 100, 100);
if (hDibNew == 0)
{
// Error
}