[GRASSLIST:298] Re: r.out.gdal problem

Jachym Cepicky jachym.cepicky at centrum.cz
Tue Mar 21 14:51:45 EST 2006


hallo,
Can be, but the values should
be there and you should be able to set some color pallet as you wish
(e.g. qgis: layer properties)

see http://les-ejk.cz/tmp/a1.png

jachym

On Tue, Mar 21, 2006 at 08:24:35PM +0100, Wolfgang Zillig wrote:
> Int32 gives very unrealistic colors see 
> http://www.student.kuleuven.ac.be/~s0167070/grass/a1.tif
> Int16 gives grayscale
> 
> 
> GRASS 6.1.cvs (uberg_mgi):/cygdrive/d/temp > r.out.gdal format=GTiff 
> metaopt=TILED=YES,COMPRESS=JPEG,JPEG_QUALITY=75 input=a1 output=a1.tif 
> type=Int32
> Writing format: GTiff
> Writing type:   Int32
> Input file size is 535, 422
> 0.Warning 1: Unable to export color table to GeoTIFF file.  Color
> tables can only be written to 1 bit 8bit GeoTIFF files.
> ..10...20...30...40...50...60...70...80...90...100 - done.
> GRASS 6.1.cvs (uberg_mgi):/cygdrive/d/temp >
> 
> Wolfgang
> 
> 
> Jachym Cepicky schrieb:
> >I would say, that type=Int32 shold work fine
> >
> >jachym
> >
> >On Tue, Mar 21, 2006 at 06:53:50PM +0100, Wolfgang Zillig wrote:
> >  
> >>My raster map is from the type CELL (with a range of [0-32767]). Can I use 
> >>(and how) r.out.gdal directly?
> >>
> >>Wolfgang
> >>
> >>
> >>
> >>Jachym Cepicky schrieb:
> >>    
> >>>Hallo,
> >>>
> >>>On Tue, Mar 21, 2006 at 04:59:43PM +0100, Wolfgang Zillig wrote:
> >>>       
> >>>>To make it clear, I have a georeferenced raster grafic. r.out.tiff works, 
> >>>>and I can do successfully:
> >>>>
> >>>>C:\Documents and Settings\s0167070>gdal_translate -of GTiff -co TILED=YES 
> >>>>-co CO
> >>>>MPRESS=JPEG -co JPEG_QUALITY=65 in.tif out.tif
> >>>>
> >>>>(But I have to say that I also have FWTools installed on my computer, I 
> >>>>haven't tried with cygwin)
> >>>>
> >>>>Is it possible to export a raster file with the command given above? Grass 
> >>>>always complains that I have to specify the "type", which I don't know.
> >>>>           
> >>>Type is, what does your r.info your_map |grep "Data Type" you.
> >>>
> >>>This will be CELL (integer), DCELL or FCELL (floating point)
> >>>
> >>>r.out.tiff makes always integers from floating point maps. via
> >>>r.out.gdal's "type" option, you can specify the precision of resulting
> >>>raster file
> >>>
> >>>hope, this helps
> >>>
> >>>Jachym
> >>>
> >>>       
> >>>>Wolfgang
> >>>>
> >>>>
> >>>>Patton, Eric schrieb:
> >>>>           
> >>>>>When you say graphic, do you mean a non-georeferenced image? I'm guessing,
> >>>>>maybe r.out.gdal is only good for georeferenced images. Have you had any
> >>>>>luck trying 'gdal_translate -of JPEG input output'?
> >>>>>
> >>>>>~ Eric.
> >>>>>-----Original Message-----
> >>>>>From: owner-GRASSLIST at baylor.edu
> >>>>>To: grasslist-en
> >>>>>Sent: 3/21/2006 10:18 AM
> >>>>>Subject: [GRASSLIST:281] r.out.gdal problem
> >>>>>
> >>>>>Hello,
> >>>>>
> >>>>>I somehow don't completely understand the usage of r.out.gdal. I prepared 
> >>>>>a graphic (which is an imported tiff) with r.composite. I can export it 
> >>>>>with r.out.tiff without any problems. But how can I use r.out.gdal to 
> >>>>>export it as JPEG (or GTiff with TILED=YES). I always fail
> >>>>>
> >>>>>to specify the correct option for the required "type". I already tried 
> >>>>>every possibility which is listed (Byte, Int16,...), but without success. 
> >>>>>What "type" do I have to use?
> >>>>>
> >>>>>Thanks
> >>>>>
> >>>>>Wolfgang
> >>>>>
> >>>>>
> >>>>>                
> >>>       
> >
> >  
> 

-- 
Jachym Cepicky                                  
e-mail: jachym.cepicky at centrum.cz           
URL: http://les-ejk.cz                      
GPG: http://les-ejk.cz/gnupg_public_key/    
-----------------------------------------   
OFFICE:                                     
Department of Geoinformation Technologies   
LDF MZLU v Brně                             
Zemědělská 3                                
613 00 Brno                                 
e-mail: xcepicky at node.mendelu.cz            
URL:    http://mapserver.mendelu.cz
Tel.:   +420 545 134 514




More information about the grass-user mailing list