Hi Jocelyn,

Sorry for not knowing the entire answer, but here are some steps.

1. Select all cells that are not white using the Raster Calculator:

"test@1" != 255 or "test@2" != 255 or "test@3" != 255


2. Set all 0 values to nodata with GRASS r.null


3. This is where I'm stuck too. :( You would like to multiply your input raster with the output of step 2 now. But I don't know how to do this in a way keeping all 3 bands in the output. (I tried the Raster Calculator, the r.mask.rast from GRASS and Raster Masking form SAGA with no luck.)

Hope someone else here can help on this?


Regards,
Raymond



On 23-05-19 15:45, Jocelyn Le Baut wrote:
Hello everybody,

I have a problem to use the raster calculator. Some pixels of my geotiff file have the value 255 on the band 1, 2 and 3. I want to replace the value by 0 on the band 1, 2 and 3 for these pixels.

I have try with this formula but it's not look good :
("test@1" != 255)+("test@2" != 255)+("test@3" != 255) * "test"

test.jpg
Thanks a lot for the help,

Jocelyn

_______________________________________________
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

_______________________________________________
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