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/psImageGeomManip.c

    r7999 r8232  
    1010 *  @author Ross Harman, MHPCC
    1111 *
    12  *  @version $Revision: 1.27 $ $Name: not supported by cvs2svn $
    13  *  @date $Date: 2006-07-28 00:44:05 $
     12 *  @version $Revision: 1.28 $ $Name: not supported by cvs2svn $
     13 *  @date $Date: 2006-08-08 23:32:23 $
    1414 *
    1515 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    3030#include "psMemory.h"
    3131#include "psAssert.h"
    32 #include "psErrorText.h"
     32
    3333#include "psCoord.h"
    3434
     
    5151    if (in == NULL) {
    5252        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    53                 PS_ERRORTEXT_psImage_IMAGE_NULL);
     53                _("Can not operate on a NULL psImage."));
    5454        psFree(out);
    5555        return NULL;
     
    5858    if (scale < 1) {
    5959        psError(PS_ERR_BAD_PARAMETER_VALUE, true,
    60                 PS_ERRORTEXT_psImageManip_SCALE_NOT_POSITIVE,
     60                _("Specified scale value, %d, must be a positive value."),
    6161                scale);
    6262        psFree(out);
     
    6666    if (stats == NULL) {
    6767        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    68                 PS_ERRORTEXT_psImage_STAT_NULL);
     68                _("Specified statistic can not be NULL."));
    6969        psFree(out);
    7070        return NULL;
     
    7474    if (statistic == 0) {
    7575        psError(PS_ERR_BAD_PARAMETER_VALUE, true,
    76                 PS_ERRORTEXT_psImage_BAD_STAT,
     76                _("Specified statistic option, %d, is not valid.  Must specify one and only one statistic type."),
    7777                stats->options);
    7878        psFree(out);
     
    8787            PS_TYPE_NAME(typeStr,mask->type.type);
    8888            psError(PS_ERR_BAD_PARAMETER_TYPE, true,
    89                     PS_ERRORTEXT_psImage_IMAGE_MASK_TYPE,
     89                    _("Input psImage mask type, %s, is not the supported mask datatype of %s."),
    9090                    typeStr, PS_TYPE_MASK_NAME);
    9191            psFree(out);
     
    159159            PS_TYPE_NAME(typeStr,in->type.type);
    160160            psError(PS_ERR_BAD_PARAMETER_TYPE, true,
    161                     PS_ERRORTEXT_psImage_IMAGE_TYPE_UNSUPPORTED,
     161                    _("Specified psImage type, %s, is not supported."),
    162162                    typeStr);
    163163            psFree(out);
     
    184184    if (in == NULL) {
    185185        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    186                 PS_ERRORTEXT_psImage_IMAGE_NULL);
     186                _("Can not operate on a NULL psImage."));
    187187        psFree(out);
    188188        return NULL;
     
    191191    if (scale < 1) {
    192192        psError(PS_ERR_BAD_PARAMETER_VALUE, true,
    193                 PS_ERRORTEXT_psImageManip_SCALE_NOT_POSITIVE,
     193                _("Specified scale value, %d, must be a positive value."),
    194194                scale);
    195195        psFree(out);
     
    199199    if (mode > PS_INTERPOLATE_LANCZOS4_VARIANCE ) {
    200200        psError(PS_ERR_BAD_PARAMETER_VALUE, true,
    201                 PS_ERRORTEXT_psImageManip_INTERPOLATION_MODE_UNSUPPORTED,
     201                _("Specified interpolation mode, %d, is unsupported."),
    202202                mode);
    203203        psFree(out);
     
    241241            PS_TYPE_NAME(typeStr,in->type.type);
    242242            psError(PS_ERR_BAD_PARAMETER_TYPE, true,
    243                     PS_ERRORTEXT_psImage_IMAGE_TYPE_UNSUPPORTED,
     243                    _("Specified psImage type, %s, is not supported."),
    244244                    typeStr);
    245245            psFree(out);
     
    262262    if (input == NULL) {
    263263        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    264                 PS_ERRORTEXT_psImage_IMAGE_NULL);
     264                _("Can not operate on a NULL psImage."));
    265265        psFree(out);
    266266        return NULL;
     
    311311    if (input == NULL) {
    312312        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    313                 PS_ERRORTEXT_psImage_IMAGE_NULL);
     313                _("Can not operate on a NULL psImage."));
    314314        psFree(out);
    315315        return NULL;
     
    357357                PS_TYPE_NAME(typeStr,type);
    358358                psError(PS_ERR_BAD_PARAMETER_TYPE, true,
    359                         PS_ERRORTEXT_psImage_IMAGE_TYPE_UNSUPPORTED,
     359                        _("Specified psImage type, %s, is not supported."),
    360360                        typeStr);
    361361                psFree(out);
     
    403403                PS_TYPE_NAME(typeStr,type);
    404404                psError(PS_ERR_BAD_PARAMETER_TYPE, true,
    405                         PS_ERRORTEXT_psImage_IMAGE_TYPE_UNSUPPORTED,
     405                        _("Specified psImage type, %s, is not supported."),
    406406                        typeStr);
    407407                psFree(out);
     
    448448                PS_TYPE_NAME(typeStr,type);
    449449                psError(PS_ERR_BAD_PARAMETER_TYPE, true,
    450                         PS_ERRORTEXT_psImage_IMAGE_TYPE_UNSUPPORTED,
     450                        _("Specified psImage type, %s, is not supported."),
    451451                        typeStr);
    452452                psFree(out);
     
    503503                    cimag(exposed) > PS_MAX_##TYPE) { \
    504504                psError(PS_ERR_BAD_PARAMETER_VALUE, true, \
    505                         PS_ERRORTEXT_psImageManip_CLIP_VALUE_INVALID, \
     505                        _("Specified %s value, %g%+gi, is not the the range of input psImage's valid pixel values (%s), i.e. [%g:%g]."), \
    506506                        "exposed", \
    507507                        creal(exposed),cimag(exposed), \
     
    570570                PS_TYPE_NAME(typeStr,type); \
    571571                psError(PS_ERR_BAD_PARAMETER_TYPE, true, \
    572                         PS_ERRORTEXT_psImage_IMAGE_TYPE_UNSUPPORTED, \
     572                        _("Specified psImage type, %s, is not supported."), \
    573573                        typeStr); \
    574574                psFree(out); \
     
    584584        default:
    585585            psError(PS_ERR_BAD_PARAMETER_VALUE, true,
    586                     PS_ERRORTEXT_psImageManip_INTERPOLATION_MODE_UNSUPPORTED,
     586                    _("Specified interpolation mode, %d, is unsupported."),
    587587                    mode);
    588588            psFree(out);
     
    608608    if (input == NULL) {
    609609        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    610                 PS_ERRORTEXT_psImage_IMAGE_NULL);
     610                _("Can not operate on a NULL psImage."));
    611611        psFree(out);
    612612        return NULL;
     
    627627            cimag(exposed) > PS_MAX_##TYPE) { \
    628628        psError(PS_ERR_BAD_PARAMETER_VALUE, true, \
    629                 PS_ERRORTEXT_psImageManip_CLIP_VALUE_INVALID, \
     629                _("Specified %s value, %g%+gi, is not the the range of input psImage's valid pixel values (%s), i.e. [%g:%g]."), \
    630630                "exposed", \
    631631                creal(exposed),cimag(exposed), \
     
    666666            PS_TYPE_NAME(typeStr,type); \
    667667            psError(PS_ERR_BAD_PARAMETER_TYPE, true, \
    668                     PS_ERRORTEXT_psImage_IMAGE_TYPE_UNSUPPORTED, \
     668                    _("Specified psImage type, %s, is not supported."), \
    669669                    typeStr); \
    670670            psFree(out); \
     
    680680    default:
    681681        psError(PS_ERR_BAD_PARAMETER_VALUE, true,
    682                 PS_ERRORTEXT_psImageManip_INTERPOLATION_MODE_UNSUPPORTED,
     682                _("Specified interpolation mode, %d, is unsupported."),
    683683                mode);
    684684        psFree(out);
     
    702702    if (input == NULL) {
    703703        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    704                 PS_ERRORTEXT_psImage_IMAGE_NULL);
     704                _("Can not operate on a NULL psImage."));
    705705        psFree(output);
    706706        return NULL;
     
    715715        if (input->numRows != inputMask->numRows || input->numCols != inputMask->numCols) {
    716716            psError(PS_ERR_BAD_PARAMETER_SIZE, true,
    717                     PS_ERRORTEXT_psImage_IMAGE_MASK_SIZE,
     717                    _("Input psImage mask size, %dx%d, does not match psImage input size, %dx%d."),
    718718                    input->numCols, input->numRows,
    719719                    inputMask->numCols, inputMask->numRows );
     
    725725            PS_TYPE_NAME(typeStr,inputMask->type.type);
    726726            psError(PS_ERR_BAD_PARAMETER_TYPE, true,
    727                     PS_ERRORTEXT_psImage_IMAGE_MASK_TYPE,
     727                    _("Input psImage mask type, %s, is not the supported mask datatype of %s."),
    728728                    typeStr, PS_TYPE_MASK_NAME);
    729729            psFree(output);
     
    734734    if (outToIn == NULL) {
    735735        psError(PS_ERR_BAD_PARAMETER_NULL, true,
    736                 PS_ERRORTEXT_psImageManip_TRANSFORM_NULL);
     736                _("Specified input transform can not be NULL."));
    737737        return NULL;
    738738    }
     
    853853            PS_TYPE_NAME(typeStr,type); \
    854854            psError(PS_ERR_BAD_PARAMETER_TYPE, true, \
    855                     PS_ERRORTEXT_psImage_IMAGE_TYPE_UNSUPPORTED, \
     855                    _("Specified psImage type, %s, is not supported."), \
    856856                    typeStr); \
    857857            psFree(output); \
     
    867867    default:
    868868        psError(PS_ERR_BAD_PARAMETER_VALUE, true,
    869                 PS_ERRORTEXT_psImageManip_INTERPOLATION_MODE_UNSUPPORTED,
     869                _("Specified interpolation mode, %d, is unsupported."),
    870870                mode);
    871871        psFree(output);
Note: See TracChangeset for help on using the changeset viewer.