It appears to me that the raster calculator treats a nodata pixel the same as any other pixel, performing the requested operation on the nodata pixel as if it were a valid value. In addition, it appears that there is no way to create an output raster that has a nodata value.*  Are these two statements correct?

I know that I can write a formula
        (raster@1 = <nodata>) * <nodata> + (raster@1 != <nodata>) * <whatever you want for valid pixels>

but this requires you know the nodata value. Even in this case, the resulting raster does not encode that value as nodata.







*The GDAL processing algorithm "Raster Calculator" does allow specifying a nodata value
_______________________________________________
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Reply via email to