Assuming you are working with an image with part of it containing no-data (that is blank) with uniform color in the no-data area.
From the loaded rater data below; You will notice the black pixels at the right and bottom of the image. Let’s remove that in these step-by-step guide.
Note that the no-data values here is black color pixels which has 0 as the RGB value. It can be of different pixel color in some cases, so we need to know the color's RGB value.
This color is usually black or white, but it can be any color it doesn't matter. All you have to do it determine the RGB values of that color occupying your no-data area.
For example: the RGB value for black color is 0 and that of white is 255. You can use this link to get the RGB values of some common colors.
Now, since we know the color value of our no-data area on our raster, lets learn how to remove the black/white or any color no-data values on raster images in QGIS using these step-by-step guide.
Step 1: Right-click on the raster layer and select Properties.
Step 2: Go to the Transparency tab, and add "0" as an Additional no data value, since in our case the unnecessary portion of the image is black.
That is it!
Thanks for reading.
From the loaded rater data below; You will notice the black pixels at the right and bottom of the image. Let’s remove that in these step-by-step guide.
This color is usually black or white, but it can be any color it doesn't matter. All you have to do it determine the RGB values of that color occupying your no-data area.
For example: the RGB value for black color is 0 and that of white is 255. You can use this link to get the RGB values of some common colors.
Now, since we know the color value of our no-data area on our raster, lets learn how to remove the black/white or any color no-data values on raster images in QGIS using these step-by-step guide.
Step 2: Go to the Transparency tab, and add "0" as an Additional no data value, since in our case the unnecessary portion of the image is black.
That is it!
Thanks for reading.
Hi Umar,
ReplyDeleteThe above method does not remove no data values from a raster it just doesn't display the no data values. After applying the above method check the no data value in the raster's metadata. Still 0.