IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jun 11, 2004, 9:18:41 AM (22 years ago)
Author:
desonia
Message:

moved the .d files into a build directory.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/test/image/tst_psImageIO.c

    r999 r1001  
    66 *  @author Robert DeSonia, MHPCC
    77 *
    8  *  @version $Revision: 1.2 $ $Name: not supported by cvs2svn $
    9  *  @date $Date: 2004-06-11 18:50:49 $
     8 *  @version $Revision: 1.3 $ $Name: not supported by cvs2svn $
     9 *  @date $Date: 2004-06-11 19:18:41 $
    1010 *
    1111 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    1616#include <string.h>
    1717#include <stdlib.h>
     18#include <sys/stat.h>
     19#include <sys/types.h>
    1820
    1921#include "psTest.h"
     
    172174
    173175    #define testReadType(TYP,filename) \
    174     testReadTypeSize(1,1,0,0,1,1,TYP,"1x1_" filename); \
    175     testReadTypeSize(M,1,M/4,0,M/2,1,TYP,"Mx1_" filename); \
    176     testReadTypeSize(1,N,0,N/4,1,N/2,TYP,"1xN_" filename); \
    177     testReadTypeSize(M,N,M/4,N/4,M/2,N/2,TYP,"MxN_" filename);
     176    mkdir("tmpImages",0777); \
     177    testReadTypeSize(1,1,0,0,1,1,TYP,"tmpImages/1x1_" filename); \
     178    testReadTypeSize(M,1,M/4,0,M/2,1,TYP,"tmpImages/Mx1_" filename); \
     179    testReadTypeSize(1,N,0,N/4,1,N/2,TYP,"tmpImages/1xN_" filename); \
     180    testReadTypeSize(M,N,M/4,N/4,M/2,N/2,TYP,"tmpImages/MxN_" filename);
    178181
    179182    testReadType(U8,"U8.fits");
     
    222225
    223226    psLogMsg(__func__,PS_LOG_INFO,"Following should be an error as extnum is invalid.");
    224     image = psImageReadSection(image,0,0,M,N,0,NULL,4,"MxN_F32.fits");
     227    image = psImageReadSection(image,0,0,M,N,0,NULL,4,"tmpImages/MxN_F32.fits");
    225228    if (image != NULL) {
    226229        psError(__func__,"Image returned though extnum was invalid.");
     
    228231    }
    229232    psLogMsg(__func__,PS_LOG_INFO,"Following should be an error as extname is invalid.");
    230     image = psImageReadSection(image,0,0,M,N,0,"bogus",0,"MxN_F32.fits");
     233    image = psImageReadSection(image,0,0,M,N,0,"bogus",0,"tmpImages/MxN_F32.fits");
    231234    if (image != NULL) {
    232235        psError(__func__,"Image returned though extnum was invalid.");
     
    288291    GENIMAGE(img,m,n,F32,0);
    289292    GENIMAGE(img2,m,n,F32,row+2*col);
     293    mkdir("tmpImages",0777);
    290294    remove
    291295        ("writeTest.fits");
    292     if (psImageWriteSection(img,0,0,0,NULL,0,"writeTest.fits") != 0) {
     296    if (psImageWriteSection(img,0,0,0,NULL,0,"tmpImages/writeTest.fits") != 0) {
    293297        psError(__func__,"Couldn't write writeTest.fits.");
    294298        return 14;
    295299    }
    296     if (psImageWriteSection(img2,0,0,0,NULL,0,"writeTest.fits") != 0) {
     300    if (psImageWriteSection(img2,0,0,0,NULL,0,"tmpImages/writeTest.fits") != 0) {
    297301        psError(__func__,"Couldn't overwrite writeTest.fits.");
    298302        return 15;
     
    302306
    303307    // Did it really overwrite the pixel values?  Let's read it in and see.
    304     img = psImageReadSection(NULL,0,0,m,n,0,NULL,0,"writeTest.fits");
     308    img = psImageReadSection(NULL,0,0,m,n,0,NULL,0,"tmpImages/writeTest.fits");
    305309    if (img == NULL) {
    306310        psError(__func__,"Could not read in writeTest.fits.");
Note: See TracChangeset for help on using the changeset viewer.