Opened 15 years ago
Closed 6 years ago
#1077 closed enhancement (fixed)
sync nice features of r.out.tiff, r.out.png
Reported by: | hamish | Owned by: | |
---|---|---|---|
Priority: | normal | Milestone: | 6.4.6 |
Component: | Raster | Version: | svn-releasebranch64 |
Keywords: | r.out.tiff, r.out.png | Cc: | |
CPU: | All | Platform: | All |
Description
Hi,
r.out.tiff has a -t flag to create a world file. r.out.png has a -t flag to make NULL cells transparent.
it would be really useful if they both could have both flags. For use with gdal2tiles.py + OpenLayers you need both but only can get one or the other! Probably it is some pretty easy cutting and pasting of code between the two modules.
GDAL supports extensions of .pgw, .pngw or .wld for PNG World files. http://gdal.org/frmt_various.html#PNG
(& finally, rename the flags in grass7 to make them consistent)
r.out.gdal is no good here because for OpenLayers you care about the colors not the data, and gdal is cranky with color maps.
thanks, Hamish
Change History (6)
comment:1 by , 15 years ago
follow-up: 3 comment:2 by , 15 years ago
- world file export flag added to r.out.png in trunk (r42410)
- (now output is good for KML and WMS/TMS overlays!)
- r.out.tiff's -t flag renamed to -w in trunk to match
does TIFF support transparency?
Hamish
comment:3 by , 15 years ago
Replying to hamish:
does TIFF support transparency?
Yes.
More importantly, transparency is supported by most applications which read TIFF files. What information can be stored in a TIFF file is often less important than what information programs which "support TIFF" understand (e.g. the problems with 16-bit paletted images).
comment:5 by , 9 years ago
Milestone: | 6.5.0 → 6.4.6 |
---|---|
Version: | svn-trunk → svn-releasebranch64 |
comment:6 by , 6 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
The current situation is:
r.out.tiff:
-w Output TIFF world file
r.out.png:
-t Make NULL cells transparent -w Output world file
So for r.out.png it is addressed fully. For r.out.tiff partially. However, r.out.tiff was moved from core to addons and the web export case is really about r.out.png. Closing as fixed.
workaround: run both r.out.tiff and r.out.png and ship the world file from r.out.tiff with the png from r.out.png