IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Aug 8, 2006, 1:32:23 PM (20 years ago)
Author:
jhoblitt
Message:

bug #790 - remove psErrorText.h and inline all error codes. all newly inlined error codes are wrapped with the _() macro from future gettextification

Location:
trunk/psLib/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src

    • Property svn:ignore
      •  

        old new  
        1010libpslib.la.temp
        1111config.h.in
        12 psErrorText.h
        1312*.bb
        1413*.bbg
  • trunk/psLib/src/imageops/psImagePixelExtract.c

    r7999 r8232  
    88 *  @author Robert DeSonia, MHPCC
    99 *
    10  *  @version $Revision: 1.25 $ $Name: not supported by cvs2svn $
    11  *  @date $Date: 2006-07-28 00:44:05 $
     10 *  @version $Revision: 1.26 $ $Name: not supported by cvs2svn $
     11 *  @date $Date: 2006-08-08 23:32:23 $
    1212 *
    1313 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    2121#include "psError.h"
    2222
    23 #include "psErrorText.h"
     23
    2424
    2525#define VECTOR_STORE_ROW_CASE(TYPE) \
     
    3434    if (input == NULL || input->data.V == NULL) {
    3535        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    36                 PS_ERRORTEXT_psImage_IMAGE_NULL);
     36                _("Can not operate on a NULL psImage."));
    3737        psFree(out);
    3838        return NULL;
     
    124124    if (input == NULL || input->data.V == NULL) {
    125125        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    126                 PS_ERRORTEXT_psImage_IMAGE_NULL);
     126                _("Can not operate on a NULL psImage."));
    127127        psFree(out);
    128128        return NULL;
     
    223223    if (input == NULL || input->data.V == NULL) {
    224224        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    225                 PS_ERRORTEXT_psImage_IMAGE_NULL);
     225                _("Can not operate on a NULL psImage."));
    226226        psFree(out);
    227227        return NULL;
     
    350350        if (inRows != mask->numRows || inCols != mask->numCols) {
    351351            psError(PS_ERR_BAD_PARAMETER_VALUE, true,
    352                     PS_ERRORTEXT_psImage_IMAGE_MASK_SIZE,
     352                    _("Input psImage mask size, %dx%d, does not match psImage input size, %dx%d."),
    353353                    mask->numCols,mask->numRows,
    354354                    inCols, inRows);
     
    360360            PS_TYPE_NAME(typeStr,mask->type.type);
    361361            psError(PS_ERR_BAD_PARAMETER_TYPE, true,
    362                     PS_ERRORTEXT_psImage_IMAGE_MASK_TYPE,
     362                    _("Input psImage mask type, %s, is not the supported mask datatype of %s."),
    363363                    typeStr, PS_TYPE_MASK_NAME);
    364364            psFree(out);
     
    369369    if (stats == NULL) {
    370370        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    371                 PS_ERRORTEXT_psImage_STAT_NULL);
     371                _("Specified statistic can not be NULL."));
    372372        psFree(out);
    373373        return NULL;
     
    378378    if (statistic == 0) {
    379379        psError(PS_ERR_BAD_PARAMETER_VALUE, false,
    380                 PS_ERRORTEXT_psImage_BAD_STAT,stats->options);
     380                _("Specified statistic option, %d, is not valid.  Must specify one and only one statistic type."),stats->options);
    381381        psFree(out);
    382382        return NULL;
     
    466466                PS_TYPE_NAME(typeStr,type);
    467467                psError(PS_ERR_BAD_PARAMETER_TYPE, true,
    468                         PS_ERRORTEXT_psImage_IMAGE_TYPE_UNSUPPORTED,
     468                        _("Specified psImage type, %s, is not supported."),
    469469                        typeStr);
    470470                psFree(out);
     
    531531    } else { // don't know what the direction flag is
    532532        psError(PS_ERR_BAD_PARAMETER_VALUE, true,
    533                 PS_ERRORTEXT_psImage_SLICE_DIRECTION_INVALID,
     533                _("Specified slice direction, %d, is invalid."),
    534534                direction);
    535535        psFree(out);
     
    555555    if (input == NULL || input->data.V == NULL) {
    556556        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    557                 PS_ERRORTEXT_psImage_IMAGE_NULL);
     557                _("Can not operate on a NULL psImage."));
    558558        psFree(out);
    559559        return NULL;
     
    588588    if (nSamples < 2) {
    589589        psError(PS_ERR_BAD_PARAMETER_VALUE, true,
    590                 PS_ERRORTEXT_psImage_nSamples_TOOSMALL,
     590                _("Specified number of samples, %d, must be greater than 1 to make a line."),
    591591                nSamples);
    592592        psFree(out);
     
    639639    if (mode < PS_INTERPOLATE_FLAT ) {
    640640        psError(PS_ERR_BAD_PARAMETER_VALUE, true,
    641                 PS_ERRORTEXT_psImageManip_INTERPOLATION_MODE_UNSUPPORTED,
     641                _("Specified interpolation mode, %d, is unsupported."),
    642642                mode);
    643643        psFree(out);
     
    648648        if (numRows != mask->numRows || numCols != mask->numCols) {
    649649            psError(PS_ERR_BAD_PARAMETER_VALUE, true,
    650                     PS_ERRORTEXT_psImage_IMAGE_MASK_SIZE,
     650                    _("Input psImage mask size, %dx%d, does not match psImage input size, %dx%d."),
    651651                    mask->numCols,mask->numRows,
    652652                    numCols-1, numRows);
     
    658658            PS_TYPE_NAME(typeStr,mask->type.type);
    659659            psError(PS_ERR_BAD_PARAMETER_TYPE, true,
    660                     PS_ERRORTEXT_psImage_IMAGE_MASK_TYPE,
     660                    _("Input psImage mask type, %s, is not the supported mask datatype of %s."),
    661661                    typeStr, PS_TYPE_MASK_NAME);
    662662            psFree(out);
     
    719719            PS_TYPE_NAME(typeStr,input->type.type);
    720720            psError(PS_ERR_BAD_PARAMETER_TYPE, true,
    721                     PS_ERRORTEXT_psImage_IMAGE_TYPE_UNSUPPORTED,
     721                    _("Specified psImage type, %s, is not supported."),
    722722                    typeStr);
    723723            psFree(out);
     
    742742    if (input == NULL || input->data.V == NULL) {
    743743        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    744                 PS_ERRORTEXT_psImage_IMAGE_NULL);
     744                _("Can not operate on a NULL psImage."));
    745745        psFree(out);
    746746        return NULL;
     
    752752        if (numRows != mask->numRows || numCols != mask->numCols) {
    753753            psError(PS_ERR_BAD_PARAMETER_SIZE, true,
    754                     PS_ERRORTEXT_psImage_IMAGE_MASK_SIZE,
     754                    _("Input psImage mask size, %dx%d, does not match psImage input size, %dx%d."),
    755755                    mask->numCols,mask->numRows,
    756756                    numCols, numRows);
     
    762762            PS_TYPE_NAME(typeStr,mask->type.type);
    763763            psError(PS_ERR_BAD_PARAMETER_TYPE, true,
    764                     PS_ERRORTEXT_psImage_IMAGE_MASK_TYPE,
     764                    _("Input psImage mask type, %s, is not the supported mask datatype of %s."),
    765765                    typeStr, PS_TYPE_MASK_NAME);
    766766            psFree(out);
     
    774774            y < input->row0 || y >= (input->row0 + numRows) ) {
    775775        psError(PS_ERR_BAD_PARAMETER_VALUE, true,
    776                 PS_ERRORTEXT_psImage_CENTER_NOT_IN_IMAGE,
     776                _("Specified center, (%g,%g), is outside of the psImage boundaries, [0:%d,0:%d]."),
    777777                x, y,
    778778                numCols-1, numRows-1);
     
    783783    if (radii == NULL) {
    784784        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    785                 PS_ERRORTEXT_psImage_RADII_VECTOR_NULL);
     785                _("Specified radii vector can not be NULL."));
    786786        psFree(out);
    787787        return NULL;
     
    790790    if (radii->n < 2) {
    791791        psError(PS_ERR_BAD_PARAMETER_SIZE, true,
    792                 PS_ERRORTEXT_psImage_RADII_VECTOR_TOOSMALL,
     792                _("Input radii vector size, %d, can not be less than 2."),
    793793                radii->n);
    794794        psFree(out);
     
    798798    if (stats == NULL) {
    799799        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    800                 PS_ERRORTEXT_psImage_STAT_NULL);
     800                _("Specified statistic can not be NULL."));
    801801        psFree(out);
    802802        return NULL;
     
    807807    if (statistic == 0) {
    808808        psError(PS_ERR_BAD_PARAMETER_VALUE, false,
    809                 PS_ERRORTEXT_psImage_BAD_STAT,
     809                _("Specified statistic option, %d, is not valid.  Must specify one and only one statistic type."),
    810810                stats->options);
    811811        psFree(out);
Note: See TracChangeset for help on using the changeset viewer.