- Timestamp:
- Dec 8, 2009, 7:11:15 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/20091201/ppSim/src/ppSimAddNoise.c
r18011 r26374 16 16 psMetadata *recipe = psMetadataLookupMetadata(NULL, config->recipes, PPSIM_RECIPE); // Recipe 17 17 18 float gain = psMetadataLookupF32(NULL, cell->concepts, "CELL.GAIN"); // CCD gain, e/ADU 18 // the recipe should set GAIN to NAN, and only modify to override the concept value 19 float gain = psMetadataLookupF32(&mdok, recipe, "GAIN"); // CCD gain, e/ADU 19 20 if (isnan(gain)) { 20 psWarning("CELL.GAIN is not set; reverting to recipe value GAIN."); 21 gain = psMetadataLookupF32(&mdok, recipe, "GAIN"); 21 gain = psMetadataLookupF32(&mdok, cell->concepts, "CELL.GAIN"); 22 22 if (!mdok) { 23 ps Error(PS_ERR_BAD_PARAMETER_VALUE, false, "Unable to find GAIN in recipe.");24 return false;23 psWarning("CELL.GAIN is not set; assuming gain of 1.0."); 24 gain = 1.0; 25 25 } 26 26 }
Note:
See TracChangeset
for help on using the changeset viewer.
