Changeset 2105 for trunk/psLib/src/image/psImageManip.c
- Timestamp:
- Oct 13, 2004, 3:22:59 PM (22 years ago)
- File:
-
- 1 edited
-
trunk/psLib/src/image/psImageManip.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/src/image/psImageManip.c
r1941 r2105 10 10 * @author Ross Harman, MHPCC 11 11 * 12 * @version $Revision: 1.2 7$ $Name: not supported by cvs2svn $13 * @date $Date: 2004-10- 02 02:08:00$12 * @version $Revision: 1.28 $ $Name: not supported by cvs2svn $ 13 * @date $Date: 2004-10-14 01:22:59 $ 14 14 * 15 15 * Copyright 2004 Maui High Performance Computing Center, University of Hawaii … … 569 569 return NULL; 570 570 } 571 572 if (scale < 1) { 573 psErrorMsg(PS_ERRORNAME_DOMAIN "psImageResample", 574 PS_ERR_BAD_PARAMETER_VALUE, true, 575 PS_ERRORTEXT_psImageManip_SCALE_NOT_POSITIVE, 576 scale); 577 psFree(out); 578 return NULL; 579 } 580 581 if (mode < PS_INTERPOLATE_FLAT || mode >= PS_INTERPOLATE_NUM_MODES) { 582 psErrorMsg(PS_ERRORNAME_DOMAIN "psImageResample", 583 PS_ERR_BAD_PARAMETER_VALUE, true, 584 PS_ERRORTEXT_psImageManip_INTERPOLATION_MODE_UNSUPPORTED, 585 mode); 586 psFree(out); 587 return NULL; 588 } 589 571 590 // create an output image of the same size 572 591 // and type … … 582 601 float inRow = (float)row * invScale; \ 583 602 for (int col=0;col<outCols;col++) { \ 584 rowData[col] = psImagePixelInterpolate(in, inRow,(float)col*invScale,NULL,0,0,mode); \603 rowData[col] = psImagePixelInterpolate(in,(float)col*invScale,inRow,NULL,0,0,mode); \ 585 604 } \ 586 605 } \
Note:
See TracChangeset
for help on using the changeset viewer.
