File: qgsrastermatrix.sip

package info (click to toggle)
qgis 2.18.28%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 1,007,948 kB
  • sloc: cpp: 671,774; python: 158,539; xml: 35,690; ansic: 8,346; sh: 1,766; perl: 1,669; sql: 999; yacc: 836; lex: 461; makefile: 292
file content (91 lines) | stat: -rw-r--r-- 2,398 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
class QgsRasterMatrix
{
%TypeHeaderCode
#include <qgsrastermatrix.h>
%End

  public:

    enum TwoArgOperator
    {
      opPLUS,
      opMINUS,
      opMUL,
      opDIV,
      opPOW,
      opEQ,         // =
      opNE,         // != resp. <>
      opGT,         // >
      opLT,         // <
      opGE,         // >=
      opLE,         // <=
      opAND,
      opOR
    };

    enum OneArgOperator
    {
      opSQRT,
      opSIN,
      opCOS,
      opTAN,
      opASIN,
      opACOS,
      opATAN,
      opSIGN
    };

    /** Takes ownership of data array*/
    QgsRasterMatrix();
    //! @note note available in python bindings
    // QgsRasterMatrix( int nCols, int nRows, float* data, double nodataValue );
    QgsRasterMatrix( const QgsRasterMatrix& m );
    ~QgsRasterMatrix();

    /** Returns true if matrix is 1x1 (=scalar number)*/
    bool isNumber() const;
    double number() const;

    /** Returns data array (but not ownership)*/
    //! @note not available in python bindings
    // double* data();
    /** Returns data and ownership. Sets data and nrows, ncols of this matrix to 0*/
    //! @note not available in python bindings
    // double* takeData();

    void setData( int cols, int rows, double* data, double nodataValue );

    int nColumns() const;
    int nRows() const;

    double nodataValue() const;
    void setNodataValue( double d );

    // QgsRasterMatrix& operator=( const QgsRasterMatrix& m );
    /** Adds another matrix to this one*/
    bool add( const QgsRasterMatrix& other );
    /** Subtracts another matrix from this one*/
    bool subtract( const QgsRasterMatrix& other );
    bool multiply( const QgsRasterMatrix& other );
    bool divide( const QgsRasterMatrix& other );
    bool power( const QgsRasterMatrix& other );
    bool equal( const QgsRasterMatrix& other );
    bool notEqual( const QgsRasterMatrix& other );
    bool greaterThan( const QgsRasterMatrix& other );
    bool lesserThan( const QgsRasterMatrix& other );
    bool greaterEqual( const QgsRasterMatrix& other );
    bool lesserEqual( const QgsRasterMatrix& other );
    bool logicalAnd( const QgsRasterMatrix& other );
    bool logicalOr( const QgsRasterMatrix& other );

    bool squareRoot();
    bool sinus();
    bool asinus();
    bool cosinus();
    bool acosinus();
    bool tangens();
    bool atangens();
    bool changeSign();
    bool log();
    bool log10();
};