|
OpenCV453
|
Matrix expression representation This is a list of implemented matrix operations that can be combined in arbitrary complex expressions (here A, B stand for matrices ( Mat ), s for a scalar ( Scalar ), alpha for a real-valued scalar ( double )): [詳解]
#include <mat.hpp>
公開メンバ関数 | |
| MatExpr (const Mat &m) | |
| MatExpr (const MatOp *_op, int _flags, const Mat &_a=Mat(), const Mat &_b=Mat(), const Mat &_c=Mat(), double _alpha=1, double _beta=1, const Scalar &_s=Scalar()) | |
| operator Mat () const | |
| template<typename _Tp > | |
| operator Mat_< _Tp > () const | |
| Size | size () const |
| int | type () const |
| MatExpr | row (int y) const |
| MatExpr | col (int x) const |
| MatExpr | diag (int d=0) const |
| MatExpr | operator() (const Range &rowRange, const Range &colRange) const |
| MatExpr | operator() (const Rect &roi) const |
| MatExpr | t () const |
| MatExpr | inv (int method=DECOMP_LU) const |
| MatExpr | mul (const MatExpr &e, double scale=1) const |
| MatExpr | mul (const Mat &m, double scale=1) const |
| Mat | cross (const Mat &m) const |
| double | dot (const Mat &m) const |
| void | swap (MatExpr &b) |
公開変数類 | |
| const MatOp * | op |
| int | flags |
| Mat | a |
| Mat | b |
| Mat | c |
| double | alpha |
| double | beta |
| Scalar | s |
関連関数 | |
(これらはメソッドではありません) | |
| CV_EXPORTS MatExpr | operator+ (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator+ (const Mat &a, const Scalar &s) |
| CV_EXPORTS MatExpr | operator+ (const Scalar &s, const Mat &a) |
| CV_EXPORTS MatExpr | operator+ (const MatExpr &e, const Mat &m) |
| CV_EXPORTS MatExpr | operator+ (const Mat &m, const MatExpr &e) |
| CV_EXPORTS MatExpr | operator+ (const MatExpr &e, const Scalar &s) |
| CV_EXPORTS MatExpr | operator+ (const Scalar &s, const MatExpr &e) |
| CV_EXPORTS MatExpr | operator+ (const MatExpr &e1, const MatExpr &e2) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator+ (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator+ (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator- (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator- (const Mat &a, const Scalar &s) |
| CV_EXPORTS MatExpr | operator- (const Scalar &s, const Mat &a) |
| CV_EXPORTS MatExpr | operator- (const MatExpr &e, const Mat &m) |
| CV_EXPORTS MatExpr | operator- (const Mat &m, const MatExpr &e) |
| CV_EXPORTS MatExpr | operator- (const MatExpr &e, const Scalar &s) |
| CV_EXPORTS MatExpr | operator- (const Scalar &s, const MatExpr &e) |
| CV_EXPORTS MatExpr | operator- (const MatExpr &e1, const MatExpr &e2) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator- (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator- (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator- (const Mat &m) |
| CV_EXPORTS MatExpr | operator- (const MatExpr &e) |
| CV_EXPORTS MatExpr | operator* (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator* (const Mat &a, double s) |
| CV_EXPORTS MatExpr | operator* (double s, const Mat &a) |
| CV_EXPORTS MatExpr | operator* (const MatExpr &e, const Mat &m) |
| CV_EXPORTS MatExpr | operator* (const Mat &m, const MatExpr &e) |
| CV_EXPORTS MatExpr | operator* (const MatExpr &e, double s) |
| CV_EXPORTS MatExpr | operator* (double s, const MatExpr &e) |
| CV_EXPORTS MatExpr | operator* (const MatExpr &e1, const MatExpr &e2) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator* (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator* (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator/ (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator/ (const Mat &a, double s) |
| CV_EXPORTS MatExpr | operator/ (double s, const Mat &a) |
| CV_EXPORTS MatExpr | operator/ (const MatExpr &e, const Mat &m) |
| CV_EXPORTS MatExpr | operator/ (const Mat &m, const MatExpr &e) |
| CV_EXPORTS MatExpr | operator/ (const MatExpr &e, double s) |
| CV_EXPORTS MatExpr | operator/ (double s, const MatExpr &e) |
| CV_EXPORTS MatExpr | operator/ (const MatExpr &e1, const MatExpr &e2) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator/ (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator/ (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator< (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator< (const Mat &a, double s) |
| CV_EXPORTS MatExpr | operator< (double s, const Mat &a) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator< (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator< (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator<= (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator<= (const Mat &a, double s) |
| CV_EXPORTS MatExpr | operator<= (double s, const Mat &a) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator<= (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator<= (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator== (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator== (const Mat &a, double s) |
| CV_EXPORTS MatExpr | operator== (double s, const Mat &a) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator== (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator== (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator!= (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator!= (const Mat &a, double s) |
| CV_EXPORTS MatExpr | operator!= (double s, const Mat &a) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator!= (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator!= (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator>= (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator>= (const Mat &a, double s) |
| CV_EXPORTS MatExpr | operator>= (double s, const Mat &a) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator>= (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator>= (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator> (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator> (const Mat &a, double s) |
| CV_EXPORTS MatExpr | operator> (double s, const Mat &a) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator> (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator> (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator& (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator& (const Mat &a, const Scalar &s) |
| CV_EXPORTS MatExpr | operator& (const Scalar &s, const Mat &a) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator& (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator& (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator| (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator| (const Mat &a, const Scalar &s) |
| CV_EXPORTS MatExpr | operator| (const Scalar &s, const Mat &a) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator| (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator| (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator^ (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator^ (const Mat &a, const Scalar &s) |
| CV_EXPORTS MatExpr | operator^ (const Scalar &s, const Mat &a) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator^ (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | operator^ (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | operator~ (const Mat &m) |
| CV_EXPORTS MatExpr | min (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | min (const Mat &a, double s) |
| CV_EXPORTS MatExpr | min (double s, const Mat &a) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | min (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | min (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | max (const Mat &a, const Mat &b) |
| CV_EXPORTS MatExpr | max (const Mat &a, double s) |
| CV_EXPORTS MatExpr | max (double s, const Mat &a) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | max (const Mat &a, const Matx< _Tp, m, n > &b) |
| template<typename _Tp , int m, int n> | |
| static MatExpr | max (const Matx< _Tp, m, n > &a, const Mat &b) |
| CV_EXPORTS MatExpr | abs (const Mat &m) |
| Calculates an absolute value of each matrix element. [詳解] | |
| CV_EXPORTS MatExpr | abs (const MatExpr &e) |
Matrix expression representation This is a list of implemented matrix operations that can be combined in arbitrary complex expressions (here A, B stand for matrices ( Mat ), s for a scalar ( Scalar ), alpha for a real-valued scalar ( double )):
A+B, A-B, A+s, A-s, s+A, s-A, -AA*alphaA.mul(B), A/B, alpha/AA*BA.t() (means AT)A.inv([method]) (~ A<sup>-1</sup>), A.inv([method])*B (~ X: AX=B)A cmpop B, A cmpop alpha, alpha cmpop A, where cmpop is one of >, >=, ==, !=, <=, <. The result of comparison is an 8-bit single channel mask whose elements are set to 255 (if the particular element or pair of elements satisfy the condition) or 0.A logicop B, A logicop s, s logicop A, ~A, where logicop is one of &, |, ^.min(A, B), min(A, alpha), max(A, B), max(A, alpha)abs(A)A.cross(B), A.dot(B)Calculates an absolute value of each matrix element.
abs is a meta-function that is expanded to one of absdiff or convertScaleAbs forms:
absdiff(A, B, C)absdiff(A, Scalar::all(0), C)Mat_<Vec<uchar,n> >(abs(A*alpha + beta)) is equivalent to convertScaleAbs(A, C, alpha, beta)The output matrix has the same size and the same type as the input one except for the last case, where C is depth=CV_8U .
| m | matrix. |
これはオーバーロードされたメンバ関数です。利便性のために用意されています。元の関数との違いは引き数のみです。
| e | matrix expression. |