Ticket #3786 (new defect)
RST driver doesn't read flag_value unless flag_def'n is set
|Reported by:||sjurk||Owned by:||warmerdam|
It appears that IdrisiDataset::GetNoDataValue?() does not accept the attribute "flag_value" read from the documentation (.rdc) file unless the accompanying attribute "flag_defn" is set to something else than "none". Instead, it returns the default -9999 with pbSuccess==FALSE. The attribute "flag_defn" is usually "background" or "missing data", but is not used analytically within IDRISI, and is often ignored.
I propose to read and set NoDataValue? to the value supplied in the .rdc file if this exists, regardless of whether or not flag_defn. was supplied in the .rdc fle.
This can be accomplished by: Instead of testing: if( ! EQUAL( pszFlagDefn, "none" ) ) call mCSLFetchNameValue( poGDS->papszRDC, rdcFLAG_VALUE ) in any case, and verify the returned string before setting
dfNoData = atof_nz(string).