26 "Class hierarchy: :class:`Interface1D` > :class:`FEdge`\n"
28 "Base Class for feature edges. This FEdge can represent a silhouette,\n"
29 "a crease, a ridge/valley, a border or a suggestive contour. For\n"
30 "silhouettes, the FEdge is oriented so that the visible face lies on\n"
31 "the left of the edge. For borders, the FEdge is oriented so that the\n"
32 "face lies on the left of the edge. An FEdge can represent an initial\n"
33 "edge of the mesh or runs across a face of the initial mesh depending\n"
34 "on the smoothness or sharpness of the mesh. This class is specialized\n"
35 "into a smooth and a sharp version since their properties slightly vary\n"
36 "from one to the other.\n"
38 ".. method:: FEdge(*args)\n"
40 " Accepted call signatures:\n"
43 " - ``FEdge(brother)``\n"
45 " Builds an :class:`FEdge` using the default constructor,\n"
46 " copy constructor, or between two :class:`SVertex` objects.\n"
48 " :param brother: An FEdge object.\n"
49 " :type brother: :class:`FEdge`\n"
50 " :param first_vertex: The first SVertex.\n"
51 " :type first_vertex: :class:`SVertex`\n"
52 " :param second_vertex: The second SVertex.\n"
53 " :type second_vertex: :class:`SVertex`\n");
56 static const char *kwlist_1[] = {
"brother",
nullptr};
57 static const char *kwlist_2[] = {
"first_vertex",
"second_vertex",
nullptr};
58 PyObject *obj1 =
nullptr, *obj2 =
nullptr;
60 if (PyArg_ParseTupleAndKeywords(args,
76 else if ((
void)PyErr_Clear(),
77 PyArg_ParseTupleAndKeywords(args,
91 PyErr_SetString(PyExc_TypeError,
"invalid argument(s)");
111 if (
ELEM(keynum, 0, 1)) {
112 SVertex *v = self->
fe->operator[](keynum);
118 PyErr_Format(PyExc_IndexError,
"FEdge[index]: index %d out of range", keynum);
139 FEdge_first_svertex_doc,
140 "The first SVertex constituting this FEdge.\n"
142 ":type: :class:`SVertex`\n");
155 PyErr_SetString(PyExc_TypeError,
"value must be an SVertex");
164 FEdge_second_svertex_doc,
165 "The second SVertex constituting this FEdge.\n"
167 ":type: :class:`SVertex`\n");
180 PyErr_SetString(PyExc_TypeError,
"value must be an SVertex");
189 FEdge_next_fedge_doc,
190 "The FEdge following this one in the ViewEdge. The value is None if\n"
191 "this FEdge is the last of the ViewEdge.\n"
193 ":type: :class:`FEdge`\n");
206 PyErr_SetString(PyExc_TypeError,
"value must be an FEdge");
215 FEdge_previous_fedge_doc,
216 "The FEdge preceding this one in the ViewEdge. The value is None if\n"
217 "this FEdge is the first one of the ViewEdge.\n"
219 ":type: :class:`FEdge`\n");
232 PyErr_SetString(PyExc_TypeError,
"value must be an FEdge");
242 "The ViewEdge to which this FEdge belongs to.\n"
244 ":type: :class:`ViewEdge`\n");
257 PyErr_SetString(PyExc_TypeError,
"value must be an ViewEdge");
267 "True if this FEdge is a smooth FEdge.\n"
277 if (!PyBool_Check(value)) {
278 PyErr_SetString(PyExc_TypeError,
"value must be boolean");
288 "The Id of this FEdge.\n"
290 ":type: :class:`Id`\n");
300 PyErr_SetString(PyExc_TypeError,
"value must be an Id");
310 "The nature of this FEdge.\n"
312 ":type: :class:`Nature`\n");
321 PyErr_SetString(PyExc_TypeError,
"value must be a Nature");
332 FEdge_first_svertex_doc,
337 FEdge_second_svertex_doc,
342 FEdge_next_fedge_doc,
347 FEdge_previous_fedge_doc,
361 {
nullptr,
nullptr,
nullptr,
nullptr,
nullptr}
367 PyVarObject_HEAD_INIT(
nullptr, 0)
386 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE,
PyObject * BPy_Id_from_Id(Id &id)
bool bool_from_PyBool(PyObject *b)
PyObject * Any_BPy_FEdge_from_FEdge(FEdge &fe)
PyObject * BPy_Nature_from_Nature(ushort n)
PyObject * BPy_SVertex_from_SVertex(SVertex &sv)
PyObject * BPy_ViewEdge_from_ViewEdge(ViewEdge &ve)
PyObject * PyBool_from_bool(bool b)
static int FEdge_viewedge_set(BPy_FEdge *self, PyObject *value, void *)
static int FEdge_previous_fedge_set(BPy_FEdge *self, PyObject *value, void *)
static PyObject * FEdge_id_get(BPy_FEdge *self, void *)
static PyObject * FEdge_viewedge_get(BPy_FEdge *self, void *)
static PyObject * FEdge_first_svertex_get(BPy_FEdge *self, void *)
static PyObject * FEdge_is_smooth_get(BPy_FEdge *self, void *)
static int FEdge_is_smooth_set(BPy_FEdge *self, PyObject *value, void *)
static int FEdge_first_svertex_set(BPy_FEdge *self, PyObject *value, void *)
static PySequenceMethods BPy_FEdge_as_sequence
static PyObject * FEdge_previous_fedge_get(BPy_FEdge *self, void *)
static PyObject * FEdge_second_svertex_get(BPy_FEdge *self, void *)
static PyObject * FEdge_nature_get(BPy_FEdge *self, void *)
static PyObject * FEdge_sq_item(BPy_FEdge *self, Py_ssize_t keynum)
static int FEdge_nature_set(BPy_FEdge *self, PyObject *value, void *)
static Py_ssize_t FEdge_sq_length(BPy_FEdge *)
static int FEdge_id_set(BPy_FEdge *self, PyObject *value, void *)
static int FEdge_init(BPy_FEdge *self, PyObject *args, PyObject *kwds)
static PyObject * FEdge_next_fedge_get(BPy_FEdge *self, void *)
static int FEdge_next_fedge_set(BPy_FEdge *self, PyObject *value, void *)
static int FEdge_second_svertex_set(BPy_FEdge *self, PyObject *value, void *)
static PyGetSetDef BPy_FEdge_getseters[]
#define BPy_FEdge_Check(v)
PyDoc_STRVAR(FalseBP1D___doc__, "Class hierarchy: :class:`freestyle.types.BinaryPredicate1D` > :class:`FalseBP1D`\n" "\n" ".. method:: __call__(inter1, inter2)\n" "\n" " Always returns false.\n" "\n" " :param inter1: The first Interface1D object.\n" " :type inter1: :class:`freestyle.types.Interface1D`\n" " :param inter2: The second Interface1D object.\n" " :type inter2: :class:`freestyle.types.Interface1D`\n" " :return: False.\n" " :rtype: bool\n")
PyTypeObject Interface1D_Type
#define BPy_Nature_Check(v)
PyTypeObject SVertex_Type
#define BPy_SVertex_Check(v)
#define BPy_ViewEdge_Check(v)
ViewEdge * viewedge() const
void setVertexB(SVertex *vB)
void setViewEdge(ViewEdge *iViewEdge)
void setNextEdge(FEdge *iEdge)
void setNature(Nature::EdgeNature iNature)
void setSmooth(bool iFlag)
void setPreviousEdge(FEdge *iEdge)
void setVertexA(SVertex *vA)
Nature::EdgeNature getNature() const
PyObject_HEAD Freestyle::Interface1D * if1D