IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 41688


Ignore:
Timestamp:
Jul 7, 2021, 4:40:40 PM (5 years ago)
Author:
eugene
Message:

added {} around some isolated continue calls

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tags/ipp-ps1-20210510/psastro/src/psastroLoadGlints.c

    r41434 r41688  
    133133
    134134            // select stars that land in this region
    135             if (star->FP->x < glintRegion.x0) continue;
    136             if (star->FP->x > glintRegion.x1) continue;
    137             if (star->FP->y < glintRegion.y0) continue;
    138             if (star->FP->y > glintRegion.y1) continue;
     135            if (star->FP->x < glintRegion.x0) {continue;}
     136            if (star->FP->x > glintRegion.x1) {continue;}
     137            if (star->FP->y < glintRegion.y0) {continue;}
     138            if (star->FP->y > glintRegion.y1) {continue;}
    139139
    140140            char *glintType = psMetadataLookupStr (&status, glintItem->data.md, "GLINT.TYPE");
     
    167167
    168168            //do a rudimentary check of whether the glint enters the pixel FPA
    169             if (!strcasecmp(glintType, "TOP")    && ((star->FP->y - glintLength) > 20000.))  continue;
    170             if (!strcasecmp(glintType, "BOTTOM") && ((star->FP->y + glintLength) < -20000.))  continue;
    171             if (!strcasecmp(glintType, "LEFT")   && ((star->FP->x + glintLength) < -20000.))  continue;
    172             if (!strcasecmp(glintType, "RIGHT")  && ((star->FP->x - glintLength) > 20000.))  continue;
     169            if (!strcasecmp(glintType, "TOP")    && ((star->FP->y - glintLength) > 20000.))  {continue;}
     170            if (!strcasecmp(glintType, "BOTTOM") && ((star->FP->y + glintLength) < -20000.))  {continue;}
     171            if (!strcasecmp(glintType, "LEFT")   && ((star->FP->x + glintLength) < -20000.))  {continue;}
     172            if (!strcasecmp(glintType, "RIGHT")  && ((star->FP->x - glintLength) > 20000.))  {continue;}
    173173
    174174            if (!strcasecmp(glintType, "TOP") || !strcasecmp(glintType, "BOTTOM")) {
     
    183183                    for (int nChip = 0; nChip < fpa->chips->n; nChip++) {
    184184                        pmChip *chip = fpa->chips->data[nChip];
    185                         if (!chip) continue;
     185                        if (!chip) {continue;}
    186186
    187187                        if (!psastroFindChipInXrange (fpa, nChip, star->FP->x, 20000.)) {
     
    209209                    for (int nChip = 0; nChip < fpa->chips->n; nChip++) {
    210210                        pmChip *chip = fpa->chips->data[nChip];
    211                         if (!chip) continue;
     211                        if (!chip) {continue;}
    212212
    213213                        if (!psastroFindChipInXrange (fpa, nChip, star->FP->x, -20000.)) {
     
    232232                }
    233233
    234                 if(glintLength < GLINT_LENGTH_MIN_FPA) continue;
     234                if(glintLength < GLINT_LENGTH_MIN_FPA) {continue;}
    235235
    236236                x_glint->data.F32[0] = xFPA0;
     
    245245
    246246                        pmChip *chip = fpa->chips->data[nChip];
    247                         if (!chip) continue;
     247                        if (!chip) {continue;}
    248248
    249249                        if (!psastroFindChipInXrange (fpa, nChip, x_glint->data.F32[glint_point], y_glint->data.F32[glint_point])) {
     
    262262
    263263                        // does this glint cross this chip?
    264                         if (yFPA0 > yFPAe) continue;
    265                         if (yFPA1 < yFPAs) continue;
     264                        if (yFPA0 > yFPAe) {continue;}
     265                        if (yFPA1 < yFPAs) {continue;}
    266266
    267267
     
    287287
    288288                        // select the 0th readout of the 0th cell for this chip
    289                         if (!chip->cells) continue;
    290                         if (!chip->cells->n) continue;
     289                        if (!chip->cells) {continue;}
     290                        if (!chip->cells->n) {continue;}
    291291                        pmCell *glintCell = chip->cells->data[0];
    292                         if (!glintCell) continue;
    293                         if (!glintCell->readouts) continue;
    294                         if (!glintCell->readouts->n) continue;
     292                        if (!glintCell) {continue;}
     293                        if (!glintCell->readouts) {continue;}
     294                        if (!glintCell->readouts->n) {continue;}
    295295                        pmReadout *glintReadout = glintCell->readouts->data[0];
    296                         if (!glintReadout) continue;
     296                        if (!glintReadout) {continue;}
    297297                       
    298298                        // save the glints on the readout->analysis metadata, creating if needed
     
    332332                    for (int nChip = 0; nChip < fpa->chips->n; nChip++) {
    333333                        pmChip *chip = fpa->chips->data[nChip];
    334                         if (!chip) continue;
     334                        if (!chip) {continue;}
    335335
    336336                        if (!psastroFindChipInXrange (fpa, nChip, 20000.,star->FP->y)) {
     
    358358                    for (int nChip = 0; nChip < fpa->chips->n; nChip++) {
    359359                        pmChip *chip = fpa->chips->data[nChip];
    360                         if (!chip) continue;
     360                        if (!chip) {continue;}
    361361
    362362                        if (!psastroFindChipInXrange (fpa, nChip, -20000.,star->FP->y)) {
     
    381381                }
    382382
    383                 if(glintLength < GLINT_LENGTH_MIN_FPA) continue;
     383                if(glintLength < GLINT_LENGTH_MIN_FPA) {continue;}
    384384
    385385                x_glint->data.F32[0] = xFPA0;
     
    393393
    394394                        pmChip *chip = fpa->chips->data[nChip];
    395                         if (!chip) continue;
     395                        if (!chip) {continue;}
    396396
    397397                        if (!psastroFindChipInYrange (fpa, nChip, x_glint->data.F32[glint_point], y_glint->data.F32[glint_point])) {
     
    410410
    411411                        // does this glint cross this chip?
    412                         if (xFPA0 > xFPAe) continue;
    413                         if (xFPA1 < xFPAs) continue;
     412                        if (xFPA0 > xFPAe) {continue;}
     413                        if (xFPA1 < xFPAs) {continue;}
    414414
    415415                        //find the x-coord positions for this chip
     
    433433
    434434                        // select the 0th readout of the 0th cell for this chip
    435                         if (!chip->cells) continue;
    436                         if (!chip->cells->n) continue;
     435                        if (!chip->cells) {continue;}
     436                        if (!chip->cells->n) {continue;}
    437437                        pmCell *glintCell = chip->cells->data[0];
    438                         if (!glintCell) continue;
    439                         if (!glintCell->readouts) continue;
    440                         if (!glintCell->readouts->n) continue;
     438                        if (!glintCell) {continue;}
     439                        if (!glintCell->readouts) {continue;}
     440                        if (!glintCell->readouts->n) {continue;}
    441441                        pmReadout *glintReadout = glintCell->readouts->data[0];
    442                         if (!glintReadout) continue;
     442                        if (!glintReadout) {continue;}
    443443                       
    444444                        // save the glints on the readout->analysis metadata, creating if needed
Note: See TracChangeset for help on using the changeset viewer.