Skip to content

Commit

Permalink
merge master:
Browse files Browse the repository at this point in the history
- don't use createFromEpsg
- cleanup: don't save tiles for debugging
  • Loading branch information
jef-n committed May 21, 2012
1 parent 74a612b commit abda05c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
6 changes: 3 additions & 3 deletions src/core/qgscoordinatereferencesystem.cpp
Expand Up @@ -155,22 +155,22 @@ bool QgsCoordinateReferenceSystem::createFromOgcWmsCrs( QString theCrs )
theCrs.compare( "OGC:CRS27", Qt::CaseInsensitive ) == 0 )
{
// TODO: verify same axis orientation
return createFromEpsg( 4267 );
return createFromOgcWmsCrs( "EPSG:4267" );
}

// NAD83
if ( theCrs.compare( "CRS:83", Qt::CaseInsensitive ) == 0 ||
theCrs.compare( "OGC:CRS83", Qt::CaseInsensitive ) == 0 )
{
// TODO: verify same axis orientation
return createFromEpsg( 4269 );
return createFromOgcWmsCrs( "EPSG:4269" );
}

// WGS84
if ( theCrs.compare( "CRS:84", Qt::CaseInsensitive ) == 0 ||
theCrs.compare( "OGC:CRS84", Qt::CaseInsensitive ) == 0 )
{
createFromEpsg( 4326 );
createFromOgcWmsCrs( "EPSG:4326" );
mAxisInverted = 0;
return mIsValidFlag;
}
Expand Down
3 changes: 1 addition & 2 deletions src/providers/wms/qgswmsprovider.cpp
Expand Up @@ -1084,13 +1084,12 @@ void QgsWmsProvider::tileReplyFinished()
QgsDebugMsg( QString( "tile reply: length %1" ).arg( reply->bytesAvailable() ) );
QImage myLocalImage = QImage::fromData( reply->readAll() );

myLocalImage.save( QString( "%1/%2-tile-%3.png" ).arg( QDir::tempPath() ).arg( mTileReqNo ).arg( tileNo ) );

if ( !myLocalImage.isNull() )
{
QPainter p( mCachedImage );
p.drawImage( dst, myLocalImage );
#if 0
myLocalImage.save( QString( "%1/%2-tile-%3.png" ).arg( QDir::tempPath() ).arg( mTileReqNo ).arg( tileNo ) );
p.drawRect( dst ); // show tile bounds
p.drawText( dst, Qt::AlignCenter, QString( "(%1)\n%2,%3\n%4,%5\n%6x%7" )
.arg( tileNo )
Expand Down

0 comments on commit abda05c

Please sign in to comment.