Changeset 1022 for trunk/psLib/test/image/tst_psImageStats02.c
- Timestamp:
- Jun 14, 2004, 9:40:15 AM (22 years ago)
- File:
-
- 1 edited
-
trunk/psLib/test/image/tst_psImageStats02.c (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/test/image/tst_psImageStats02.c
r887 r1022 4 4 thouroughly tested elsewhere, we will only test psImageStats() with 5 5 the PS_STAT_SAMPLE_MEAN here. 6 7 NOTE: After you debug, set CHEBY_X_DIM != CHEBY_Y_DIM. 8 Also, uses non-square images. 6 9 *****************************************************************************/ 7 10 #include <stdio.h> … … 11 14 #include "psImage.h" 12 15 #include "psImageStats.h" 13 #define NUM_BINS 20 14 #define IMAGE_SIZE 10 15 #define CHEBY_X_DIM 5 16 #define IMAGE_SIZE 3 17 #define CHEBY_X_DIM 3 16 18 #define CHEBY_Y_DIM 3 17 19 … … 38 40 for (j=0;j<IMAGE_SIZE;j++) { 39 41 tmpImage->data.F32[i][j] = (float) (i + j); 42 tmpImage->data.F32[i][j] = 4.0; 40 43 outImage->data.F32[i][j] = 0.0; 41 }42 }43 for (i=0;i<IMAGE_SIZE;i++) {44 for (j=0;j<IMAGE_SIZE;j++) {45 printf("(%f, %f)\n", tmpImage->data.F32[i][j],46 outImage->data.F32[i][j]);47 44 } 48 45 } … … 72 69 for (i=0;i<IMAGE_SIZE;i++) { 73 70 for (j=0;j<IMAGE_SIZE;j++) { 74 printf("(%f, %f)\n", tmpImage->data.F32[i][j], 71 printf("pixel[%d][%d] is (%f, %f)\n", i, j, 72 tmpImage->data.F32[i][j], 75 73 outImage->data.F32[i][j]); 76 74 }
Note:
See TracChangeset
for help on using the changeset viewer.
