[GRASSLIST:6554] Re: MASK confussion

Maciek Sieczka werchowyna at epf.pl
Tue Apr 19 15:23:46 EDT 2005


From: "Glynn Clements" <glynn at gclements.plus.com>

> Maciek Sieczka wrote:
>
>> Is it normal and intended that "0" is taken the same as the "null" when
>> doing "r.mapcalc 'MASK=some_raster"?
>
> Yes.
>
>> It took me over an hour to guess my there where holes in my MASK.
>> Shouldn't "0" be treated as a regular, valid value for MASK?
>
> Masks used to be zero/non-zero before support for a distinguished NULL
> value was added in 5.0. The existing behaviour maintains backwards
> compatibility.

I see. But is backward compatibility so important here? IMHO all Grass 
oldtimers users got used to using NULL for no-data instead of ZERO, and 
newbies use NULL by default.

Also, all Grass commands I know use NULL for no-data. And if they support 
ZERO it is an option. Shouldn't MASK follow this?

Just my ideas.

Thanks
Maciek 




More information about the grass-user mailing list