How can I split an 4 channel rgb pic in qgis? With the value tool I can see 4 channel. I tried to use the RGB to PCT tool but I always get an error (File "C:\PROGRA~1\QGISBR~1\bin\pct2rgb.py", line 125, in ct_size = ct.GetCount() AttributeError: 'NoneType' object has no attribute 'GetCount' )
-
Now I just have a tiff with one band, and want to render this image using pct2rgb.py, but it also alert the same problem. How should I fix it? many thx! – Yue LI May 24 '18 at 12:09
gdal_translate is able to extract single bands:
gdal_translate -b 1 in.tif out1.tif
gdal_translate -b 2 in.tif out2.tif
gdal_translate -b 3 in.tif out3.tif
gdal_translate -b 4 in.tif out4.tif
Raster -> Conversion -> Translate
will create a gdal_translate command line, which you can edit to specify the band you want.