Skip to content
Permalink
Browse files

fix #3585

git-svn-id: http://svn.osgeo.org/qgis/trunk@15457 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
jef
jef committed Mar 12, 2011
1 parent 7ad5e6d commit a41769fdc94647d00b4f2cb33987e46ad9dacc2c
Showing with 5 additions and 5 deletions.
  1. +1 −1 src/app/qgswmssourceselect.cpp
  2. +4 −4 src/providers/wms/qgswmsprovider.cpp
@@ -597,7 +597,7 @@ void QgsWMSSourceSelect::addClicked()
connArgs += "GetFeatureInfo";
}

if ( connInfo.startsWith( "username=" ) )
if ( connInfo.startsWith( "username=" ) || connInfo.startsWith( "tiled=" ) )
{
connInfo.prepend( connArgs + "," );
}
@@ -567,8 +567,8 @@ QImage *QgsWmsProvider::draw( QgsRectangle const &viewExtent, int pixelWidth, i
double ymax = qMin( viewExtent.yMaximum(), layerExtent.yMaximum() );

// snap to tile coordinates
double x0 = floor(( xmin - layerExtent.xMinimum() ) / mTileWidth / tres ) * mTileWidth * tres + layerExtent.xMinimum() + mTileWidth * tres * 0.001;
double y0 = floor(( ymin - layerExtent.yMinimum() ) / mTileHeight / tres ) * mTileHeight * tres + layerExtent.yMinimum() + mTileHeight * tres * 0.001;
double x0 = floor(( xmin - layerExtent.xMinimum() ) / mTileWidth / tres ) * mTileWidth * tres + layerExtent.xMinimum(); // + mTileWidth * tres * 0.001;
double y0 = floor(( ymin - layerExtent.yMinimum() ) / mTileHeight / tres ) * mTileHeight * tres + layerExtent.yMinimum(); // + mTileHeight * tres * 0.001;

#ifdef QGISDEBUG
// calculate number of tiles
@@ -2095,7 +2095,7 @@ bool QgsWmsProvider::calculateExtent()
{
if ( tilesetsSupported[i].layers.join( "," ) == layers &&
tilesetsSupported[i].styles.join( "," ) == styles &&
tilesetsSupported[i].boundingBox.crs == imageCrs )
tilesetsSupported[i].crs == imageCrs )
{
layerExtent = tilesetsSupported[i].boundingBox.box;
return true;
@@ -2104,7 +2104,7 @@ bool QgsWmsProvider::calculateExtent()
QgsDebugMsg( QString( "mismatch layers=%1, styles=%2 and crs=%3." )
.arg( tilesetsSupported[i].layers.join( "," ) )
.arg( tilesetsSupported[i].styles.join( "," ) )
.arg( tilesetsSupported[i].boundingBox.crs ) );
.arg( tilesetsSupported[i].crs ) );
}

QgsDebugMsg( "no extent for layer" );

0 comments on commit a41769f

Please sign in to comment.
You can’t perform that action at this time.