<div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr">Personally I would create a .vrt using gdal_translate, with these "additional command line parameters":<br><br></div><div dir="ltr"> -b 1 -b 2 -b 3 -b 1 -colorinterp_4 alpha -scale_4 0 255 255 255<br><br></div><div dir="ltr">This assumes 8 bit RGB input, but you can adapt it for something else.</div><div dir="ltr">It does work even before georeferencing.</div><div dir="ltr">But depending on your workflow it might be easier just to convert to RGBA with something like imagemagick, or to open in MS Paint and save as PNG, which silently adds an alpha channel.</div><div dir="ltr"><br></div><div dir="ltr">Regards,</div><div dir="ltr">Alister<br><br>> Date: Mon, 24 Jan 2022 10:33:56 -0400<br>> From: Kirk Schmidt <<a href="mailto:kirk@nortekresources.com">kirk@nortekresources.com</a>><br>> To: <a href="mailto:qgis-user@lists.osgeo.org">qgis-user@lists.osgeo.org</a><br>> Subject: Re: [Qgis-user] Adding alpha band to raster<br>> Message-ID: <<a href="mailto:46938c47-4f37-44ac-5f96-468f29258783@nortekresources.com">46938c47-4f37-44ac-5f96-468f29258783@nortekresources.com</a>><br>> Content-Type: text/plain; charset=UTF-8; format=flowed<br>> <br>> Hi Nicolas:<br>> <br>> I just had an idea, why not use gdal directly??? I know gdalwarp has a<br>> -dstalpha switch to code null data Assuming this is what you want the<br>> alpha band for)<br>> <br>> Kirk<br>> <br>> <br>> On 1/21/2022 6:06 PM, Nicolas Cadieux wrote:<br>> > Hi,<br>> ><br>> > I don't see it in the current processing algorithms. I see lot's or<br>> > r.out... but not that one:(? I guess I could do it in Grass...<br>> ><br>> > Thanks for the idea!<br>> ><br>> > Nicolas<br>> ><br>> > On 2022-01-21 1:37 p.m., Kirk Schmidt wrote:<br>> >> Hi Nicholas:<br>> >><br>> >> Try r.out.gdal<br>> >><br>> >> <a href="https://grass.osgeo.org/grass78/manuals/r.out.gdal.html">https://grass.osgeo.org/grass78/manuals/r.out.gdal.html</a><br>> >><br>> >> Kirk Schmidt<br>> >><br>> >><br>> >> On 1/21/2022 2:25 PM, Nicolas Cadieux wrote:<br>> >>> Hi,<br>> >>><br>> >>> What is the easiest way, in QGIS3, to add an alpha band to a<br>> >>> raster?? Alpha bands are handy with the georeferencer. Currently, I<br>> >>> am just adding it in GIMP before I start the georeferencer.<br>> >>><br>> >>> Thanks</div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div>