Class cv::Range#
Template class specifying a continuous subsequence (slice) of a sequence. View details
#include <opencv2/core/types.hpp>Collaboration diagram for cv::Range:
Detailed Description#
Template class specifying a continuous subsequence (slice) of a sequence.
The class is used to specify a row or a column span in a matrix ( Mat ) and for many other purposes. Range(a,b) is basically the same as a:b in Matlab or a..b in Python. As in Python, start is an inclusive left boundary of the range and end is an exclusive right boundary of the range. Such a half-opened interval is usually denoted as \([start,end)\) .
The static method Range::all()
returns a special variable that means “the whole sequence” or “the
whole range”, just like “ : “ in Matlab or “ … “ in Python. All the methods and functions in OpenCV that take
Range support this special Range::all() value. But, of course, in case of your own custom processing, you will probably have to check and handle it explicitly:- Examples
- samples/cpp/floodfill.cpp.
Constructor & Destructor Documentation#
Range()#
Range()#
Member Function Documentation#
empty()#
bool cv::Range::empty()
size()#
int cv::Range::size()
all()#
Member Data Documentation#
end#
int cv::Range::end
start#
int cv::Range::start
Source file#
The documentation for this class was generated from the following file:
opencv2/core/types.hpp