Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Access to layer data of interpolator
  • Loading branch information
mhugent committed Mar 27, 2014
1 parent 34421c8 commit ad6d2b4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/analysis/interpolation/qgsgridfilewriter.cpp
Expand Up @@ -100,7 +100,7 @@ int QgsGridFileWriter::writeFile( bool showProgressDialog )

// create prj file
QgsInterpolator::LayerData ld;
ld = mInterpolator->mLayerData.first();
ld = mInterpolator->layerData().first();
QgsVectorLayer* vl = ld.vectorLayer;
QString crs = vl->crs().toWkt();
QFileInfo fi( mOutputFilePath );
Expand Down
4 changes: 2 additions & 2 deletions src/analysis/interpolation/qgsinterpolator.h
Expand Up @@ -64,6 +64,8 @@ class ANALYSIS_EXPORT QgsInterpolator
@return 0 in case of success*/
virtual int interpolatePoint( double x, double y, double& result ) = 0;

const QList<LayerData>& layerData() const { return mLayerData; }

protected:
/**Caches the vertex and value data from the provider. All the vertex data
will be held in virtual memory
Expand All @@ -86,8 +88,6 @@ class ANALYSIS_EXPORT QgsInterpolator
@param attributeValue the attribute value for interpolation (if not interpolated from z-coordinate)
@return 0 in case of success*/
int addVerticesToCache( QgsGeometry* geom, bool zCoord, double attributeValue );

friend class QgsGridFileWriter;
};

#endif

0 comments on commit ad6d2b4

Please sign in to comment.