Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[server] Preserve DPI for all image output formats
In particular for image/png;mode=8bit
  • Loading branch information
m-kuhn authored and nyalldawson committed Jun 8, 2020
1 parent 83b974a commit 471998c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/server/services/wms/qgswmsutils.cpp
Expand Up @@ -152,6 +152,10 @@ namespace QgsWms
break;
}

// Preserve DPI, some conversions, in particular the one for 8bit will drop this information
result.setDotsPerMeterX( img.dotsPerMeterX() );
result.setDotsPerMeterY( img.dotsPerMeterY() );

if ( outputFormat != UNKN )
{
response.setHeader( "Content-Type", contentType );
Expand Down

0 comments on commit 471998c

Please sign in to comment.