Classes | Macros | Enumerations | Functions | Variables
module_opencv4.cpp File Reference
#include "module.hpp"
#include "opencv2/core/types_c.h"
#include "opencv2/opencv_modules.hpp"
#include "pycompat.hpp"
Include dependency graph for module_opencv4.cpp:

Go to the source code of this file.

Classes

struct  ArgInfo
 
class  NumpyAllocator
 
class  PyAllowThreads
 
class  PyEnsureGIL
 

Macros

#define ERRWRAP2(expr)
 

Enumerations

enum  { ARG_NONE = 0, ARG_MAT = 1, ARG_SCALAR = 2 }
 

Functions

int convert_to_CvMat2 (const PyObject *o, cv::Mat &m)
 
static int failmsg (const char *fmt,...)
 
static PyObject * failmsgp (const char *fmt,...)
 
PyObject * pyopencv_from (const Mat &m)
 
template<typename T >
static PyObject * pyopencv_from (const T &src)
 
static bool pyopencv_to (PyObject *o, Mat &m, const ArgInfo info)
 
template<>
bool pyopencv_to (PyObject *o, Mat &m, const char *name)
 
template<typename T >
static bool pyopencv_to (PyObject *obj, T &p, const char *name="<unknown>")
 

Variables

NumpyAllocator g_numpyAllocator
 
static PyObject * opencv_error = 0
 

Macro Definition Documentation

◆ ERRWRAP2

#define ERRWRAP2 (   expr)
Value:
try \
{ \
PyAllowThreads allowThreads; \
expr; \
} \
catch (const cv::Exception &e) \
{ \
PyErr_SetString(opencv_error, e.what()); \
return 0; \
}

Definition at line 64 of file module_opencv4.cpp.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
ARG_NONE 
ARG_MAT 
ARG_SCALAR 

Definition at line 172 of file module_opencv4.cpp.

Function Documentation

◆ convert_to_CvMat2()

int convert_to_CvMat2 ( const PyObject *  o,
cv::Mat &  m 
)

Definition at line 368 of file module_opencv4.cpp.

◆ failmsg()

static int failmsg ( const char *  fmt,
  ... 
)
static

Definition at line 13 of file module_opencv4.cpp.

◆ failmsgp()

static PyObject* failmsgp ( const char *  fmt,
  ... 
)
static

Definition at line 78 of file module_opencv4.cpp.

◆ pyopencv_from() [1/2]

PyObject* pyopencv_from ( const Mat &  m)

Definition at line 352 of file module_opencv4.cpp.

◆ pyopencv_from() [2/2]

template<typename T >
static PyObject* pyopencv_from ( const T &  src)
static

◆ pyopencv_to() [1/3]

static bool pyopencv_to ( PyObject *  o,
Mat &  m,
const ArgInfo  info 
)
static

Definition at line 175 of file module_opencv4.cpp.

◆ pyopencv_to() [2/3]

template<>
bool pyopencv_to ( PyObject *  o,
Mat &  m,
const char *  name 
)

Definition at line 347 of file module_opencv4.cpp.

◆ pyopencv_to() [3/3]

template<typename T >
static bool pyopencv_to ( PyObject *  obj,
T &  p,
const char *  name = "<unknown>" 
)
static

Variable Documentation

◆ g_numpyAllocator

NumpyAllocator g_numpyAllocator

Definition at line 163 of file module_opencv4.cpp.

◆ opencv_error

PyObject* opencv_error = 0
static

Definition at line 11 of file module_opencv4.cpp.

opencv_error
static PyObject * opencv_error
Definition: module_opencv4.cpp:11


cv_bridge
Author(s): Patrick Mihelich, James Bowman
autogenerated on Wed Aug 21 2024 02:46:59