OpenCV 5.0.0-pre
Open Source Computer Vision
Loading...
Searching...
No Matches
gkernel.hpp File Reference
#include <functional>
#include <iostream>
#include <string>
#include <type_traits>
#include <unordered_map>
#include <utility>
#include <opencv2/gapi/gcommon.hpp>
#include <opencv2/gapi/util/util.hpp>
#include <opencv2/gapi/gcall.hpp>
#include <opencv2/gapi/garg.hpp>
#include <opencv2/gapi/gmetaarg.hpp>
#include <opencv2/gapi/gtype_traits.hpp>
#include <opencv2/gapi/util/compiler_hints.hpp>
#include <opencv2/gapi/gtransform.hpp>
Include dependency graph for gkernel.hpp:
This graph shows which files directly or indirectly include this file:

Classes

struct  cv::detail::CompileArgTag< cv::gapi::use_only >
 
struct  cv::detail::CompileArgTag< cv::GKernelPackage >
 
struct  cv::GKernel
 
struct  cv::GKernelImpl
 
class  cv::GKernelPackage
 A container class for heterogeneous kernel implementation collections and graph transformations. More...
 
class  cv::GKernelType< K, std::function< R(Args...)> >
 
class  cv::GKernelTypeM< K, std::function< std::tuple< R... >(Args...)> >
 
struct  cv::GTypeInfo
 
struct  std::hash< cv::gapi::GBackend >
 
class  cv::detail::KernelTypeMedium< K, std::function< R(Args...)> >
 
class  cv::detail::KernelTypeMedium< K, std::function< std::tuple< R... >(Args...)> >
 
struct  cv::detail::MetaHelper< K, std::tuple< Ins... >, Out >
 
struct  cv::detail::MetaHelper< K, std::tuple< Ins... >, std::tuple< Outs... > >
 
struct  cv::detail::MetaType< T >
 
struct  cv::detail::MetaType< cv::GArray< U > >
 
struct  cv::detail::MetaType< cv::GFrame >
 
struct  cv::detail::MetaType< cv::GMat >
 
struct  cv::detail::MetaType< cv::GMatP >
 
struct  cv::detail::MetaType< cv::GOpaque< U > >
 
struct  cv::detail::MetaType< cv::GScalar >
 
struct  cv::detail::NoTag
 
struct  cv::gapi::use_only
 cv::gapi::use_only() is a special combinator which hints G-API to use only kernels specified in cv::GComputation::compile() (and not to extend kernels available by default with that package). More...
 
struct  cv::detail::Yield< cv::GArray< U > >
 
struct  cv::detail::Yield< cv::GMat >
 
struct  cv::detail::Yield< cv::GMatP >
 
struct  cv::detail::Yield< cv::GOpaque< U > >
 
struct  cv::detail::Yield< cv::GScalar >
 
struct  cv::detail::Yield< GFrame >
 

Namespaces

namespace  cv
 
namespace  cv::detail
 
namespace  cv::gapi
 
namespace  std
 STL namespace.
 

Macros

#define __WRAP_VAARGS(x)
 
#define COMBINE_SIGNATURE(...)
 
#define G_API_OP   G_TYPED_KERNEL
 
#define G_API_OP_M   G_API_OP
 
#define G_TYPED_KERNEL(Class, ...)
 
#define G_TYPED_KERNEL_HELPER(Class, API, Id)
 
#define G_TYPED_KERNEL_HELPER_10(Class, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, Id)
 
#define G_TYPED_KERNEL_HELPER_2(Class, _1, _2, Id)
 
#define G_TYPED_KERNEL_HELPER_3(Class, _1, _2, _3, Id)
 
#define G_TYPED_KERNEL_HELPER_4(Class, _1, _2, _3, _4, Id)
 
#define G_TYPED_KERNEL_HELPER_5(Class, _1, _2, _3, _4, _5, Id)
 
#define G_TYPED_KERNEL_HELPER_6(Class, _1, _2, _3, _4, _5, _6, Id)
 
#define G_TYPED_KERNEL_HELPER_7(Class, _1, _2, _3, _4, _5, _6, _7, Id)
 
#define G_TYPED_KERNEL_HELPER_8(Class, _1, _2, _3, _4, _5, _6, _7, _8, Id)
 
#define G_TYPED_KERNEL_HELPER_9(Class, _1, _2, _3, _4, _5, _6, _7, _8, _9, Id)
 
#define G_TYPED_KERNEL_M   G_TYPED_KERNEL
 
#define GET_G_TYPED_KERNEL(_1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, NAME, ...)
 

Typedefs

using cv::GCtors = std::vector<detail::HostCtor>
 
using cv::gapi::GKernelPackage = cv::GKernelPackage
 
using cv::GKinds = std::vector<cv::detail::OpaqueKind>
 
using cv::GShapes = std::vector<GShape>
 
template<typename T >
using cv::detail::is_nongapi_type = std::is_same<T, typename MetaType<T>::type>
 

Functions

template<typename... Ps>
cv::GKernelPackage cv::gapi::combine (const cv::GKernelPackage &a, const cv::GKernelPackage &b, Ps &&... rest)
 Combines multiple G-API kernel packages into one.
 
cv::GKernelPackage cv::gapi::combine (const cv::GKernelPackage &lhs, const cv::GKernelPackage &rhs)
 
template<typename T >
std::enable_if< is_nongapi_type< T >::value, T >::type cv::detail::get_in_meta (const GMetaArgs &, const GArgs &in_args, int idx)
 
template<typename T >
std::enable_if<!is_nongapi_type< T >::value, typenameMetaType< T >::type >::type cv::detail::get_in_meta (const GMetaArgs &in_meta, const GArgs &, int idx)
 
template<typename... KK>
GKernelPackage cv::gapi::kernels ()
 Create a kernel package object containing kernels and transformations specified in variadic template argument.
 
template<typename... FF>
GKernelPackage cv::gapi::kernels (FF &... functors)
 
bool cv::gapi::operator!= (const GBackend &lhs, const GBackend &rhs)
 

Variables

class GAPI_EXPORTS_W_SIMPLE cv::GKernelPackage
 

Macro Definition Documentation

◆ __WRAP_VAARGS

#define __WRAP_VAARGS ( x)
Value:
x

◆ COMBINE_SIGNATURE

#define COMBINE_SIGNATURE ( ...)
Value:
__VA_ARGS__

◆ G_API_OP

#define G_API_OP   G_TYPED_KERNEL

◆ G_API_OP_M

#define G_API_OP_M   G_API_OP

◆ G_TYPED_KERNEL

#define G_TYPED_KERNEL ( Class,
... )
Value:
G_TYPED_KERNEL_HELPER)(Class, __VA_ARGS__)) \
#define G_TYPED_KERNEL_HELPER_7(Class, _1, _2, _3, _4, _5, _6, _7, Id)
Definition gkernel.hpp:329
#define GET_G_TYPED_KERNEL(_1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, NAME,...)
Definition gkernel.hpp:294
#define G_TYPED_KERNEL_HELPER_4(Class, _1, _2, _3, _4, Id)
Definition gkernel.hpp:320
#define G_TYPED_KERNEL_HELPER_9(Class, _1, _2, _3, _4, _5, _6, _7, _8, _9, Id)
Definition gkernel.hpp:335
#define G_TYPED_KERNEL_HELPER_6(Class, _1, _2, _3, _4, _5, _6, Id)
Definition gkernel.hpp:326
#define G_TYPED_KERNEL_HELPER_5(Class, _1, _2, _3, _4, _5, Id)
Definition gkernel.hpp:323
#define G_TYPED_KERNEL_HELPER_8(Class, _1, _2, _3, _4, _5, _6, _7, _8, Id)
Definition gkernel.hpp:332
#define G_TYPED_KERNEL_HELPER_2(Class, _1, _2, Id)
Definition gkernel.hpp:314
#define G_TYPED_KERNEL_HELPER(Class, API, Id)
Definition gkernel.hpp:308
#define G_TYPED_KERNEL_HELPER_3(Class, _1, _2, _3, Id)
Definition gkernel.hpp:317
#define G_TYPED_KERNEL_HELPER_10(Class, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, Id)
Definition gkernel.hpp:338
#define __WRAP_VAARGS(x)
Definition gkernel.hpp:297

Declares a new G-API Operation. See Kernel API for more details.

Parameters
Classtype name for this operation.

◆ G_TYPED_KERNEL_HELPER

#define G_TYPED_KERNEL_HELPER ( Class,
API,
Id )
Value:
G_ID_HELPER_BODY(Class, Id) \
struct Class final: public cv::detail::KernelTypeMedium<Class, std::function API >, \
public G_ID_HELPER_CLASS(Class)
Definition gkernel.hpp:266

Helper for G_TYPED_KERNEL declares a new G-API Operation. See Kernel API for more details.

Parameters
Classtype name for this operation.
APIan std::function<>-like signature for the operation; return type is a single value or a tuple of multiple values.
Idstring identifier for the operation. Must be unique.

◆ G_TYPED_KERNEL_HELPER_10

#define G_TYPED_KERNEL_HELPER_10 ( Class,
_1,
_2,
_3,
_4,
_5,
_6,
_7,
_8,
_9,
_10,
Id )
Value:
G_TYPED_KERNEL_HELPER(Class, COMBINE_SIGNATURE(_1, _2, _3, _4, _5, _6, _7, _8, _9, _10), Id)
#define COMBINE_SIGNATURE(...)
Definition gkernel.hpp:295

◆ G_TYPED_KERNEL_HELPER_2

#define G_TYPED_KERNEL_HELPER_2 ( Class,
_1,
_2,
Id )
Value:

◆ G_TYPED_KERNEL_HELPER_3

#define G_TYPED_KERNEL_HELPER_3 ( Class,
_1,
_2,
_3,
Id )
Value:

◆ G_TYPED_KERNEL_HELPER_4

#define G_TYPED_KERNEL_HELPER_4 ( Class,
_1,
_2,
_3,
_4,
Id )
Value:
G_TYPED_KERNEL_HELPER(Class, COMBINE_SIGNATURE(_1, _2, _3, _4), Id)

◆ G_TYPED_KERNEL_HELPER_5

#define G_TYPED_KERNEL_HELPER_5 ( Class,
_1,
_2,
_3,
_4,
_5,
Id )
Value:
G_TYPED_KERNEL_HELPER(Class, COMBINE_SIGNATURE(_1, _2, _3, _4, _5), Id)

◆ G_TYPED_KERNEL_HELPER_6

#define G_TYPED_KERNEL_HELPER_6 ( Class,
_1,
_2,
_3,
_4,
_5,
_6,
Id )
Value:
G_TYPED_KERNEL_HELPER(Class, COMBINE_SIGNATURE(_1, _2, _3, _4, _5, _6), Id)

◆ G_TYPED_KERNEL_HELPER_7

#define G_TYPED_KERNEL_HELPER_7 ( Class,
_1,
_2,
_3,
_4,
_5,
_6,
_7,
Id )
Value:
G_TYPED_KERNEL_HELPER(Class, COMBINE_SIGNATURE(_1, _2, _3, _4, _5, _6, _7), Id)

◆ G_TYPED_KERNEL_HELPER_8

#define G_TYPED_KERNEL_HELPER_8 ( Class,
_1,
_2,
_3,
_4,
_5,
_6,
_7,
_8,
Id )
Value:
G_TYPED_KERNEL_HELPER(Class, COMBINE_SIGNATURE(_1, _2, _3, _4, _5, _6, _7, _8), Id)

◆ G_TYPED_KERNEL_HELPER_9

#define G_TYPED_KERNEL_HELPER_9 ( Class,
_1,
_2,
_3,
_4,
_5,
_6,
_7,
_8,
_9,
Id )
Value:
G_TYPED_KERNEL_HELPER(Class, COMBINE_SIGNATURE(_1, _2, _3, _4, _5, _6, _7, _8, _9), Id)

◆ G_TYPED_KERNEL_M

#define G_TYPED_KERNEL_M   G_TYPED_KERNEL

Declares a new G-API Operation. See Kernel API for more details.

Deprecated
This macro is deprecated in favor of G_TYPED_KERNEL that is used for declaring any G-API Operation.
Parameters
Classtype name for this operation.

◆ GET_G_TYPED_KERNEL

#define GET_G_TYPED_KERNEL ( _1,
_2,
_3,
_4,
_5,
_6,
_7,
_8,
_9,
_10,
_11,
NAME,
... )
Value:
NAME