OpenCV 5.0.0-pre
Open Source Computer Vision
|
cv::GArray<T>
template class represents a list of objects of class T
in the graph.
More...
#include <opencv2/gapi/garray.hpp>
Public Member Functions | |
GArray () | |
Constructs an empty cv::GArray<T> | |
GArray (const std::vector< HT > &v) | |
Constructs a value-initialized cv::GArray<T> | |
GArray (std::vector< HT > &&v) | |
Constructs a value-initialized cv::GArray<T> | |
cv::GArray<T>
template class represents a list of objects of class T
in the graph.
cv::GArray<T>
describes a functional relationship between operations consuming and producing arrays of objects of class T
. The primary purpose of cv::GArray<T>
is to represent a dynamic list of objects – where the size of the list is not known at the graph construction or compile time. Examples include: corner and feature detectors (cv::GArray<cv::Point>
), object detection and tracking results (cv::GArray<cv::Rect>
). Programmers can use their own types with cv::GArray<T>
in the custom operations.
Similar to cv::GScalar
, cv::GArray<T>
may be value-initialized – in this case a graph-constant value is associated with the object.
GArray<T>
is a virtual counterpart of std::vector<T>
, which is usually used to represent the GArray<T>
data in G-API during the execution.
cv::GOpaque<T>
|
inlineexplicit |
Constructs a value-initialized cv::GArray<T>
cv::GArray<T>
objects may have their values be associated at graph construction time. It is useful when some operation has a cv::GArray<T>
input which doesn't change during the program execution, and is set only once. In this case, there is no need to declare such cv::GArray<T>
as a graph input.
cv::GArray<T>
may be overwritten by assigning some other cv::GArray<T>
to the object using operator=
– on the assignment, the old association or value is discarded.v | a std::vector<T> to associate with this cv::GArray<T> object. Vector data is copied into the cv::GArray<T> (no reference to the passed data is held). |
|
inlineexplicit |
Constructs a value-initialized cv::GArray<T>
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
v | a std::vector<T> to associate with this cv::GArray<T> object. Vector data is moved into the cv::GArray<T> . |
|
inline |
Constructs an empty cv::GArray<T>
Normally, empty G-API data objects denote a starting point of the graph. When an empty cv::GArray<T>
is assigned to a result of some operation, it obtains a functional link to this operation (and is not empty anymore).