Cirrus Logic CS485 Dokumentacja Strona 231

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 319
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów
Przeglądanie stron 230
Geometric Transforms
11-9
11
Example 11-1 Using Macro Definition to Resize an Image
int ResizeFit( void ) {
IplImage *imga = iplCreateImageJaehne(
IPL_DEPTH_8U, 5, 5 );
IplImage *imgb = iplCreateImageJaehne(
IPL_DEPTH_8U, 7, 7 );
IPLStatus st;
iplResizeFit( imga, imgb, IPL_INTER_NN );
st = iplGetErrStatus();
iplDeallocate( imga, IPL_IMAGE_ALL );
iplDeallocate( imgb, IPL_IMAGE_ALL );
return IPL_StsOk == st;
}
Changing the Image Orientation
The functions described in this section change the image orientation by
rotating or mirroring the source image. Rotation involves image resampling
by using various kinds of interpolation: nearest neighbor, linear, or cubic
interpolation (see Appendix B). Mirroring is performed by flipping the
image axis in horizontal or vertical direction.
Rotate
Rotates an image
around the (0,0) origin.
void iplRotate(IplImage*
srcImage
, IplImage*
dstImage
,
double
angle
, double
xShift
, double
yShift,
int
interpolate
);
srcImage
Thesourceimage.
Przeglądanie stron 230
1 2 ... 226 227 228 229 230 231 232 233 234 235 236 ... 318 319

Komentarze do niniejszej Instrukcji

Brak uwag