[FWTools] gdal_merge color and res issue

james2009 gkenny_2000 at yahoo.com
Tue Feb 17 14:43:27 EST 2009


My image is (shown in image info from OpenEV):
USA:
1024*768*1 Bands GeoTiff
World:
582*309*1 Bands GeoTiff.


I try different -ps option but it doesn't make any different in result.
Maybe is a problem of color table to generate this two tiff image? 
I generate the two image use gdal_translate -a_ullr option on gif to tif
format. An I doing wrong? Or is that a way I need to set for these two image
using same color table (using gdal_translate?)

Thanks

Tom


Travis Kirstine wrote:
> 
> Are both your images single band with a color table?  Gdal_merge
> assumes that all images have the same colour table if single band (I
> think).  You may have to convert the images to RGB (pct2rgb.py) before
> the merge.  Gdal also uses the last images resolution for the output
> (world geotiff).  You can set the resolution with the -ps parameter.
> You may want to try gdalwarp to do the merge instead and make use of
> the different types of resampling
> 
> gdalwarp -tr 100 100 -r cubic input1.tif input2.tif output.tif
> 
> Regards
> 
> 2009/2/12 james2009 <gkenny_2000 at yahoo.com>:
>>
>> Hi all,
>>
>> I am trying to merge two Geotiff into one. They are a world and US
>> Geotiff
>> images. It looks fine on layer overlap in OpenEV tool (us show in right
>> area
>> in world background and in color). But when I try to merge them into one
>> using gdal_merge.py (FWTools 206 Linux), it become BW and lose lot of
>> res.
>> Would you please help me out with this issue?
>>
>> I am looking for a way to automate this process.
>>
>> Thanks for the help.
>>
>> Tom
>> --
>> View this message in context:
>> http://www.nabble.com/gdal_merge-color-and-res-issue-tp21956550p21956550.html
>> Sent from the FWTools mailing list archive at Nabble.com.
>>
>> _______________________________________________
>> FWTools mailing list
>> FWTools at lists.maptools.org
>> http://lists.maptools.org/mailman/listinfo/fwtools
>> http://fwtools.maptools.org/
>>
> 
> 
> 
> -- 
> Travis K.
> 
> Toronto, Canada
> ------------------------------------------------------------
> "She knows there's no success like failure
> And that failure's no success at all."
> -Bob Dylan-
> ------------------------------------------------------------
> _______________________________________________
> FWTools mailing list
> FWTools at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/fwtools
> http://fwtools.maptools.org/
> 
> 

-- 
View this message in context: http://www.nabble.com/gdal_merge-color-and-res-issue-tp21956550p22064795.html
Sent from the FWTools mailing list archive at Nabble.com.



More information about the FWTools mailing list