Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Remove debug output
  • Loading branch information
elpaso committed Feb 2, 2019
1 parent 1aef9cf commit 1923967
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/core/raster/qgshillshaderenderer.cpp
Expand Up @@ -32,7 +32,6 @@
#endif
#include "qgsexception.h"
#include "qgsopenclutils.h"
#include "qdebug.h"
#endif

QgsHillshadeRenderer::QgsHillshadeRenderer( QgsRasterInterface *input, int band, double lightAzimuth, double lightAngle ):
Expand Down Expand Up @@ -215,14 +214,13 @@ QgsRasterBlock *QgsHillshadeRenderer::block( int bandNo, const QgsRectangle &ext
typeName = QStringLiteral( "float" );
break;
default:
throw QgsException( QStringLiteral( "Unsupported data type for OpenCL processing.") );
throw QgsException( QStringLiteral( "Unsupported data type for OpenCL processing." ) );
}

if ( inputBlock->dataType() != Qgis::DataType::Float32 )
{
source.replace(QStringLiteral( "__global float *scanLine" ), QStringLiteral( "__global %1 *scanLine" ).arg( typeName ));
source.replace( QStringLiteral( "__global float *scanLine" ), QStringLiteral( "__global %1 *scanLine" ).arg( typeName ) );
}
qDebug() << source;

// Data type for input is Float32 (4 bytes)
std::size_t scanLineWidth( inputBlock->width() + 2 );
Expand Down Expand Up @@ -280,7 +278,7 @@ QgsRasterBlock *QgsHillshadeRenderer::block( int bandNo, const QgsRectangle &ext

static std::map<Qgis::DataType, cl::Program> programCache;
cl::Program program = programCache[inputBlock->dataType()];
if (! program.get() )
if ( ! program.get() )
{
// Create a program from the kernel source
programCache[inputBlock->dataType()] = QgsOpenClUtils::buildProgram( source, QgsOpenClUtils::ExceptionBehavior::Throw );
Expand Down

0 comments on commit 1923967

Please sign in to comment.