Opened 14 years ago

Last modified 5 years ago

#977 new enhancement

WxGUI "Save display to graphic file" should write out an World file

Reported by: marisn Owned by: grass-dev@…
Priority: minor Milestone: 7.6.2
Component: wxGUI Version: svn-trunk
Keywords: wxgui Cc:
CPU: Unspecified Platform: Unspecified


Current wxgui version tool "Save display to graphic file" creates image file without any coordinate information. As Map Canvas already has information about extent, it would be trivial to dump that information into world file and thus make simple screen dumps georeferenced. QGIS and ArcGIS support such option.

Change History (12)

comment:1 by hamish, 14 years ago

Version: svn-releasebranch64svn-trunk

for the xmon version use 'd.out.file format=geotiff'.

while this is possible it is not necessarily a good idea. it should only be used when there is a need to composite multiple layers (scalebars, decorations, and all) into a geotiff, which is generally a solution of last resort.

from the d.out.file mane page:

       GeoTIFF export is provided as  a  convenience.  For
       raster export it is generally preferable to use the
       r.out.gdal or r.out.tiff modules. The advantage  of
       using  d.out.file  is  that  you can easily overlay
       multiple raster maps, vector maps, and  decorations
       into  the  GeoTIFF at the expense of resolution and
       quality. If  you  wish  to  minimize  the  negative
       effects, use "g.region align=" or "g.region rast=",
       then "g.region -g" or " -g" to  discover  the
       raster  rows and columns of the map, and feed these
       numbers  into  d.out.file's   size   parameter   as


comment:2 by marisn, 14 years ago

It's not about GeoTIFFs but about writing out World file. It's a nice meta-data add-on. It's not meant to replace proper data export for analysis, but can serve well to keep tracks of various screen dumps.

I.e. if I want to know what (where) I was using as a sample data to create PNG image with some random content for lectures, I can simply load that PNG into QGIS and see it's location. Probably writing out some other meta data according to some ISO spec would also be fine, still World file (i.e. .pgw) is also a nice start.

comment:3 by hamish, 14 years ago

see also #822

comment:4 by martinl, 8 years ago


comment:5 by martinl, 8 years ago


comment:6 by kuszinger, 8 years ago

Only a short note:

When map display window is resized, the resulting image file covers the same area and stripes of background colour may appear top/bottom or at the sides.

Saving display to graphic file will contain these "empty" areas. The relation of the proposed world file area (coordinates) to the displayed area (including empty areas) should be considered and handled. The user should also be informed well about these facts.

BTW - I wonder if there is any drawback of always painting/filling the whole display canvas.

comment:7 by martinl, 8 years ago


Milestone renamed

comment:8 by neteler, 6 years ago


Ticket retargeted after milestone closed

comment:9 by neteler, 6 years ago


comment:10 by martinl, 6 years ago


All enhancement tickets should be assigned to 7.6 milestone.

comment:11 by martinl, 5 years ago


Ticket retargeted after milestone closed

comment:12 by martinl, 5 years ago


Ticket retargeted after milestone closed

Note: See TracTickets for help on using tickets.