IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Nov 3, 2004, 3:05:00 PM (22 years ago)
Author:
desonia
Message:

changed the psError signature to match SDRS. Also made misc. cleanups as
I was combing the files.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/astro/psCoord.c

    r2221 r2273  
    1010*  @author George Gusciora, MHPCC
    1111*
    12 *  @version $Revision: 1.32 $ $Name: not supported by cvs2svn $
    13 *  @date $Date: 2004-10-27 23:31:43 $
     12*  @version $Revision: 1.33 $ $Name: not supported by cvs2svn $
     13*  @date $Date: 2004-11-04 01:04:57 $
    1414*
    1515*  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    2727#include "psConstants.h"
    2828#include "psError.h"
     29#include "psAstronomyErrors.h"
    2930#include <math.h>
    3031#include <float.h>
     
    278279
    279280    } else if (projection->type == PS_PROJ_PAR) {
    280         psError(__func__, "The projection type PS_PROJ_PAR is undefined.\n");
     281        psError(PS_ERR_BAD_PARAMETER_TYPE, true,
     282                PS_ERRORTEXT_psCoord_PROJECTION_TYPE_UNDEFINED,
     283                "PS_PROJ_PAR");
    281284
    282285    } else if (projection->type == PS_PROJ_GLS) {
    283         psError(__func__, "The projection type PS_PROJ_GLS is undefined.\n");
     286        psError(PS_ERR_BAD_PARAMETER_TYPE, true,
     287                PS_ERRORTEXT_psCoord_PROJECTION_TYPE_UNDEFINED,
     288                "PS_PROJ_GLS");
    284289    } else {
    285         psError(__func__, "Unknown projection type.\n");
     290        psError(PS_ERR_BAD_PARAMETER_TYPE, true,
     291                PS_ERRORTEXT_psCoord_PROJECTION_TYPE_UNKNOWN,
     292                projection->type);
    286293    }
    287294
     
    333340
    334341    } else if (projection->type == PS_PROJ_PAR) {
    335         psError(__func__, "The projection type PS_PROJ_PAR is undefined.\n");
     342        psError(PS_ERR_BAD_PARAMETER_TYPE, true,
     343                PS_ERRORTEXT_psCoord_PROJECTION_TYPE_UNDEFINED,
     344                "PS_PROJ_PAR");
    336345
    337346    } else if (projection->type == PS_PROJ_GLS) {
    338         psError(__func__, "The projection type PS_PROJ_GLG is undefined.\n");
     347        psError(PS_ERR_BAD_PARAMETER_TYPE, true,
     348                PS_ERRORTEXT_psCoord_PROJECTION_TYPE_UNDEFINED,
     349                "PS_PROJ_GLS");
    339350    } else {
    340         psError(__func__, "Unknown projection type.\n");
     351        psError(PS_ERR_BAD_PARAMETER_TYPE, true,
     352                PS_ERRORTEXT_psCoord_PROJECTION_TYPE_UNKNOWN,
     353                projection->type);
    341354    }
    342355
     
    407420        } else if (unit == PS_RADIAN) {}
    408421        else {
    409             psError(__func__, "Unknown offset unit: 0x%x\n", unit);
     422            psError(PS_ERR_BAD_PARAMETER_VALUE, true,
     423                    PS_ERRORTEXT_psCoord_UNITS_UNKNOWN,
     424                    unit);
    410425        }
    411426
     
    413428    }
    414429
    415     psError(__func__, "Unrecognized offset mode\n");
     430    psError(PS_ERR_BAD_PARAMETER_VALUE, true,
     431            PS_ERRORTEXT_psCoord_OFFSET_MODE_UNKNOWN,
     432            mode);
    416433    return (NULL);
    417434}
     
    469486            tmpD = offset->d;
    470487        } else {
    471             psError(__func__, "Unknown offset unit: 0x%x\n", unit);
     488            psError(PS_ERR_BAD_PARAMETER_VALUE, true,
     489                    PS_ERRORTEXT_psCoord_UNITS_UNKNOWN,
     490                    unit);
    472491        }
    473492
     
    483502    }
    484503
    485     psError(__func__, "Unrecognized offset mode\n");
     504    psError(PS_ERR_BAD_PARAMETER_VALUE, true,
     505            PS_ERRORTEXT_psCoord_OFFSET_MODE_UNKNOWN,
     506            mode);
     507
    486508    return (NULL);
    487509}
Note: See TracChangeset for help on using the changeset viewer.