Blender  V3.3
BPy_ViewMapGradientNormBP1D.cpp
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2 
8 
9 #include "../BPy_Convert.h"
10 #include "../BPy_IntegrationType.h"
11 
12 #ifdef __cplusplus
13 extern "C" {
14 #endif
15 
16 using namespace Freestyle;
17 
19 
20 //------------------------INSTANCE METHODS ----------------------------------
21 
22 // ViewMapGradientNormBP1D(int level, IntegrationType iType=MEAN, float sampling=2.0)
23 
25  "Class hierarchy: :class:`freestyle.types.BinaryPredicate1D` > "
26  ":class:`ViewMapGradientNormBP1D`\n"
27  "\n"
28  ".. method:: __init__(level, integration_type=IntegrationType.MEAN, sampling=2.0)\n"
29  "\n"
30  " Builds a ViewMapGradientNormBP1D object.\n"
31  "\n"
32  " :arg level: The level of the pyramid from which the pixel must be\n"
33  " read.\n"
34  " :type level: int\n"
35  " :arg integration_type: The integration method used to compute a single value\n"
36  " from a set of values.\n"
37  " :type integration_type: :class:`freestyle.types.IntegrationType`\n"
38  " :arg sampling: The resolution used to sample the chain:\n"
39  " GetViewMapGradientNormF0D is evaluated at each sample point and\n"
40  " the result is obtained by combining the resulting values into a\n"
41  " single one, following the method specified by integration_type.\n"
42  " :type sampling: float\n"
43  "\n"
44  ".. method:: __call__(inter1, inter2)\n"
45  "\n"
46  " Returns true if the evaluation of the Gradient norm Function is\n"
47  " higher for inter1 than for inter2.\n"
48  "\n"
49  " :arg inter1: The first Interface1D object.\n"
50  " :type inter1: :class:`freestyle.types.Interface1D`\n"
51  " :arg inter2: The second Interface1D object.\n"
52  " :type inter2: :class:`freestyle.types.Interface1D`\n"
53  " :return: True or false.\n"
54  " :rtype: bool\n";
55 
57  PyObject *args,
58  PyObject *kwds)
59 {
60  static const char *kwlist[] = {"level", "integration_type", "sampling", nullptr};
61  PyObject *obj = nullptr;
62  int i;
63  float f = 2.0;
64 
65  if (!PyArg_ParseTupleAndKeywords(
66  args, kwds, "i|O!f", (char **)kwlist, &i, &IntegrationType_Type, &obj, &f)) {
67  return -1;
68  }
70  self->py_bp1D.bp1D = new Predicates1D::ViewMapGradientNormBP1D(i, t, f);
71  return 0;
72 }
73 
74 /*-----------------------BPy_ViewMapGradientNormBP1D type definition ----------------------------*/
75 
77  PyVarObject_HEAD_INIT(nullptr, 0) "ViewMapGradientNormBP1D", /* tp_name */
78  sizeof(BPy_ViewMapGradientNormBP1D), /* tp_basicsize */
79  0, /* tp_itemsize */
80  nullptr, /* tp_dealloc */
81  0, /* tp_vectorcall_offset */
82  nullptr, /* tp_getattr */
83  nullptr, /* tp_setattr */
84  nullptr, /* tp_reserved */
85  nullptr, /* tp_repr */
86  nullptr, /* tp_as_number */
87  nullptr, /* tp_as_sequence */
88  nullptr, /* tp_as_mapping */
89  nullptr, /* tp_hash */
90  nullptr, /* tp_call */
91  nullptr, /* tp_str */
92  nullptr, /* tp_getattro */
93  nullptr, /* tp_setattro */
94  nullptr, /* tp_as_buffer */
95  Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, /* tp_flags */
97  nullptr, /* tp_traverse */
98  nullptr, /* tp_clear */
99  nullptr, /* tp_richcompare */
100  0, /* tp_weaklistoffset */
101  nullptr, /* tp_iter */
102  nullptr, /* tp_iternext */
103  nullptr, /* tp_methods */
104  nullptr, /* tp_members */
105  nullptr, /* tp_getset */
106  &BinaryPredicate1D_Type, /* tp_base */
107  nullptr, /* tp_dict */
108  nullptr, /* tp_descr_get */
109  nullptr, /* tp_descr_set */
110  0, /* tp_dictoffset */
111  (initproc)ViewMapGradientNormBP1D___init__, /* tp_init */
112  nullptr, /* tp_alloc */
113  nullptr, /* tp_new */
114 };
115 
117 
118 #ifdef __cplusplus
119 }
120 #endif
PyTypeObject BinaryPredicate1D_Type
IntegrationType IntegrationType_from_BPy_IntegrationType(PyObject *obj)
PyTypeObject IntegrationType_Type
static int ViewMapGradientNormBP1D___init__(BPy_ViewMapGradientNormBP1D *self, PyObject *args, PyObject *kwds)
PyTypeObject ViewMapGradientNormBP1D_Type
static char ViewMapGradientNormBP1D___doc__[]
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint GLsizei GLsizei GLenum type _GL_VOID_RET _GL_VOID GLsizei GLenum GLenum const void *pixels _GL_VOID_RET _GL_VOID const void *pointer _GL_VOID_RET _GL_VOID GLdouble v _GL_VOID_RET _GL_VOID GLfloat v _GL_VOID_RET _GL_VOID GLint GLint i2 _GL_VOID_RET _GL_VOID GLint j _GL_VOID_RET _GL_VOID GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble GLdouble GLdouble zFar _GL_VOID_RET _GL_UINT GLdouble *equation _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLenum GLfloat *v _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLfloat *values _GL_VOID_RET _GL_VOID GLushort *values _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLenum GLdouble *params _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_BOOL GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLushort pattern _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble u2 _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLdouble GLdouble v2 _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLdouble GLdouble nz _GL_VOID_RET _GL_VOID GLfloat GLfloat nz _GL_VOID_RET _GL_VOID GLint GLint nz _GL_VOID_RET _GL_VOID GLshort GLshort nz _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const GLfloat *values _GL_VOID_RET _GL_VOID GLsizei const GLushort *values _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID const GLuint const GLclampf *priorities _GL_VOID_RET _GL_VOID GLdouble y _GL_VOID_RET _GL_VOID GLfloat y _GL_VOID_RET _GL_VOID GLint y _GL_VOID_RET _GL_VOID GLshort y _GL_VOID_RET _GL_VOID GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLfloat GLfloat z _GL_VOID_RET _GL_VOID GLint GLint z _GL_VOID_RET _GL_VOID GLshort GLshort z _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble w _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat w _GL_VOID_RET _GL_VOID GLint GLint GLint w _GL_VOID_RET _GL_VOID GLshort GLshort GLshort w _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble y2 _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat y2 _GL_VOID_RET _GL_VOID GLint GLint GLint y2 _GL_VOID_RET _GL_VOID GLshort GLshort GLshort y2 _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLuint *buffer _GL_VOID_RET _GL_VOID GLdouble t _GL_VOID_RET _GL_VOID GLfloat t _GL_VOID_RET _GL_VOID GLint t _GL_VOID_RET _GL_VOID GLshort t _GL_VOID_RET _GL_VOID GLdouble t
inherits from class Rep
Definition: AppCanvas.cpp:18