[GRASSLIST:7571] Re: r.in.gdal splittsimage in R G B

Glynn Clements glynn at gclements.plus.com
Sun Jul 17 07:21:02 EDT 2005


Axel Orth wrote:

> All the images I got before could be imported in GRASS using r.in.gdal 
> and became "one image".
> Now i import other data and the image is split in its R G B components 
> and I get 3 images.
> 
> What can I do to get one image from the beginning or merge the 3 together ?

You can merge them with r.composite.

Since r.composite was added, programs such as r.in.gdal no longer
generate composite maps automatically, but produce separate bands.

The main reasons for this is that composite maps normally have reduced
intensity resolution; the default is 32 intensity levels per
component, whereas separate bands will normally use 256 intensity
levels.

While it's possible to generate composite maps with 256 intensity
levels per component, the resulting maps have huge colour tables
(65536 rules covering 16777216 categories), and processing them tends
to be very slow and uses a lot of memory.

Several key operations which can be performed on a composite map have
equivalents which operate upon separate bands, e.g.:

	d.rast		d.rgb
	r.out.ppm	r.out.ppm3
	ps.map/raster	ps.map/rgb

-- 
Glynn Clements <glynn at gclements.plus.com>




More information about the grass-user mailing list