Skip to content

Commit 61b599e

Browse files
committedNov 29, 2016
Added histogram values to the bindings
1 parent 0ee93ee commit 61b599e

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed
 

‎python/core/raster/qgsrasterhistogram.sip

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ class QgsRasterHistogram
44
#include <qgsrasterhistogram.h>
55
%End
66
public:
7+
8+
typedef QVector<int> HistogramVector;
9+
710
QgsRasterHistogram();
811

912
/** Compares region, size etc. not histogram itself */
@@ -22,9 +25,9 @@ class QgsRasterHistogram
2225
bool includeOutOfRange;
2326

2427
/** \brief Store the histogram for a given layer
25-
* @note not available via python binding
26-
*/
27-
// HistogramVector histogramVector;
28+
* @note added in version 3.0
29+
*/
30+
HistogramVector histogramVector;
2831

2932
/** \brief The maximum histogram value. */
3033
double maximum;

3 commit comments

Comments
 (3)

3nids commented on Aug 2, 2017

@3nids
Member

@elpaso have you been able to use this? @alexbruy seems to have issues with it: https://lists.osgeo.org/pipermail/qgis-developer/2017-August/049498.html

elpaso commented on Aug 3, 2017

@elpaso
ContributorAuthor

IIRC I tested I and it was working correctly when I exposed the histogramVector to the bindings. I stepped into that while I was testing the IPython integration and I wanted to display a chart inside the console, the vector with the data was not accessible from Python, that's why I re-enabled it.

elpaso commented on Sep 30, 2017

@elpaso
ContributorAuthor
Please sign in to comment.