[gdal-dev] using GDAL to make a multi band image from several one-band images

Yann Chemin yann.chemin at gmail.com
Thu Jan 3 03:08:04 EST 2008


Hello,

I would like to use GDAL (in Python) for doing something like this.

------------------------------------------------------
src1 = LoadfFile('file1.extension')
src1 = AddBlankLayers(45) # Increase the number of bands of the image
src1[0] = LoadFile('file1.extension')
src1[2] = LoadFile('file1.extension')
.....
src1[44] = LoadFile('file45.extension')
src1[45] = LoadFile('file46.extension')
SaveArrayWithGeo(src1,....,'HFA') #Finally, save the multiband image
------------------------------------------------------

The idea is to create a new file from an already existing one-band
file, only thing is to have it multi-band.

Maybe It is not the best way to start doing it...

Could anybody help please?
thanks
Yann


More information about the gdal-dev mailing list