Improvements in error handling at Python-C++ boundaries.
This commit is contained in:
@@ -153,15 +153,18 @@ PyObject * BinaryPredicate0D_getName( BPy_BinaryPredicate0D *self, PyObject *arg
|
||||
PyObject * BinaryPredicate0D___call__( BPy_BinaryPredicate0D *self, PyObject *args)
|
||||
{
|
||||
BPy_Interface0D *obj1, *obj2;
|
||||
bool b;
|
||||
|
||||
if( !PyArg_ParseTuple(args,(char *)"OO", &obj1, &obj2) ) {
|
||||
cout << "ERROR: BinaryPredicate0D___call__ " << endl;
|
||||
if( !PyArg_ParseTuple(args, "O!O!", &Interface0D_Type, &obj1, &Interface0D_Type, &obj2) )
|
||||
return NULL;
|
||||
|
||||
if (self->bp0D->operator()( *(obj1->if0D) , *(obj2->if0D) ) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->bp0D->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
b = self->bp0D->operator()( *(obj1->if0D) , *(obj2->if0D) );
|
||||
return PyBool_from_bool( b );
|
||||
return PyBool_from_bool( self->bp0D->result );
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -182,15 +182,18 @@ PyObject *BinaryPredicate1D_getName( BPy_BinaryPredicate1D *self, PyObject *args
|
||||
PyObject *BinaryPredicate1D___call__( BPy_BinaryPredicate1D *self, PyObject *args)
|
||||
{
|
||||
BPy_Interface1D *obj1, *obj2;
|
||||
bool b;
|
||||
|
||||
if( !PyArg_ParseTuple(args,(char *)"OO", &obj1, &obj2) ) {
|
||||
cout << "ERROR: BinaryPredicate1D___call__ " << endl;
|
||||
if( !PyArg_ParseTuple(args, "O!O!", &Interface1D_Type, &obj1, &Interface1D_Type, &obj2) )
|
||||
return NULL;
|
||||
|
||||
if (self->bp1D->operator()( *(obj1->if1D) , *(obj2->if1D) ) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->bp1D->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
b = self->bp1D->operator()( *(obj1->if1D) , *(obj2->if1D) );
|
||||
return PyBool_from_bool( b );
|
||||
return PyBool_from_bool( self->bp1D->result );
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -165,19 +165,24 @@ PyObject * UnaryPredicate0D___call__( BPy_UnaryPredicate0D *self, PyObject *args
|
||||
{
|
||||
PyObject *py_if0D_it;
|
||||
|
||||
if(!( PyArg_ParseTuple(args, "O", &py_if0D_it) && BPy_Interface0DIterator_Check(py_if0D_it) )) {
|
||||
cout << "ERROR: UnaryPredicate0D___call__ " << endl;
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &py_if0D_it) )
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Interface0DIterator *if0D_it = ((BPy_Interface0DIterator *) py_if0D_it)->if0D_it;
|
||||
|
||||
if( if0D_it )
|
||||
return PyBool_from_bool( self->up0D->operator()(*if0D_it) );
|
||||
else
|
||||
cerr << "ERROR: UnaryPredicate0D___call__ (no Interface0DIterator)" << endl;
|
||||
|
||||
Py_RETURN_NONE;
|
||||
if( !if0D_it ) {
|
||||
string msg(self->up0D->getName() + " has no Interface0DIterator");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
return NULL;
|
||||
}
|
||||
if (self->up0D->operator()(*if0D_it) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->up0D->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
return PyBool_from_bool( self->up0D->result );
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -207,19 +207,24 @@ PyObject * UnaryPredicate1D___call__( BPy_UnaryPredicate1D *self, PyObject *args
|
||||
{
|
||||
PyObject *py_if1D;
|
||||
|
||||
if(!( PyArg_ParseTuple(args, "O", &py_if1D) && BPy_Interface1D_Check(py_if1D) )) {
|
||||
cout << "ERROR: UnaryPredicate1D___call__ " << endl;
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &py_if1D) )
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Interface1D *if1D = ((BPy_Interface1D *) py_if1D)->if1D;
|
||||
|
||||
if( if1D )
|
||||
return PyBool_from_bool( self->up1D->operator()(*if1D) );
|
||||
else
|
||||
cerr << "ERROR: UnaryPredicate1D___call__ (no Interface1D)" << endl;
|
||||
|
||||
Py_RETURN_NONE;
|
||||
if( !if1D ) {
|
||||
string msg(self->up1D->getName() + " has no Interface0DIterator");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
return NULL;
|
||||
}
|
||||
if( self->up1D->operator()(*if1D) < 0 ) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->up1D->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
return PyBool_from_bool( self->up1D->result );
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -43,123 +43,108 @@
|
||||
|
||||
|
||||
// BinaryPredicate0D: __call__
|
||||
bool Director_BPy_BinaryPredicate0D___call__( PyObject *obj, Interface0D& i1, Interface0D& i2) {
|
||||
int Director_BPy_BinaryPredicate0D___call__( PyObject *obj, Interface0D& i1, Interface0D& i2) {
|
||||
PyObject *arg1 = BPy_Interface0D_from_Interface0D(i1);
|
||||
PyObject *arg2 = BPy_Interface0D_from_Interface0D(i2);
|
||||
PyObject *result = PyObject_CallMethod( obj, "__call__", "OO", arg1, arg2 );
|
||||
Py_DECREF(arg1);
|
||||
Py_DECREF(arg2);
|
||||
if (!result) {
|
||||
cerr << "Warning: BinaryPredicate0D::__call__() failed." << endl;
|
||||
PyErr_Clear();
|
||||
return false;
|
||||
}
|
||||
bool ret = bool_from_PyBool(result);
|
||||
if (!result)
|
||||
return -1;
|
||||
int ret = PyObject_IsTrue(result);
|
||||
Py_DECREF(result);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
// BinaryPredicate1D: __call__
|
||||
bool Director_BPy_BinaryPredicate1D___call__( PyObject *obj, Interface1D& i1, Interface1D& i2) {
|
||||
PyObject *arg1 = BPy_Interface1D_from_Interface1D(i1);
|
||||
PyObject *arg2 = BPy_Interface1D_from_Interface1D(i2);
|
||||
int Director_BPy_BinaryPredicate1D___call__( PyObject *obj, Interface1D& i1, Interface1D& i2) {
|
||||
PyObject *arg1, *arg2;
|
||||
PyObject *result = PyObject_CallMethod( obj, "__call__", "OO", arg1, arg2 );
|
||||
Py_DECREF(arg1);
|
||||
Py_DECREF(arg2);
|
||||
if (!result) {
|
||||
cerr << "Warning: BinaryPredicate1D::__call__() failed." << endl;
|
||||
PyErr_Clear();
|
||||
return false;
|
||||
}
|
||||
bool ret = bool_from_PyBool(result);
|
||||
if (!result)
|
||||
return -1;
|
||||
int ret = PyObject_IsTrue(result);
|
||||
Py_DECREF(result);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
// UnaryPredicate0D: __call__
|
||||
bool Director_BPy_UnaryPredicate0D___call__( PyObject *obj, Interface0DIterator& if0D_it) {
|
||||
int Director_BPy_UnaryPredicate0D___call__( PyObject *obj, Interface0DIterator& if0D_it) {
|
||||
PyObject *arg = BPy_Interface0DIterator_from_Interface0DIterator(if0D_it);
|
||||
PyObject *result = PyObject_CallMethod( obj, "__call__", "O", arg );
|
||||
Py_DECREF(arg);
|
||||
if (!result) {
|
||||
cerr << "Warning: UnaryPredicate0D::__call__() failed." << endl;
|
||||
PyErr_Clear();
|
||||
return false;
|
||||
}
|
||||
bool ret = bool_from_PyBool(result);
|
||||
if (!result)
|
||||
return -1;
|
||||
int ret = PyObject_IsTrue(result);
|
||||
Py_DECREF(result);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
// UnaryPredicate1D: __call__
|
||||
bool Director_BPy_UnaryPredicate1D___call__( PyObject *obj, Interface1D& if1D) {
|
||||
PyObject *arg = BPy_Interface1D_from_Interface1D(if1D);
|
||||
int Director_BPy_UnaryPredicate1D___call__( PyObject *obj, Interface1D& if1D) {
|
||||
PyObject *arg;
|
||||
PyObject *result = PyObject_CallMethod( obj, "__call__", "O", arg );
|
||||
Py_DECREF(arg);
|
||||
if (!result) {
|
||||
cerr << "Warning: UnaryPredicate1D::__call__() failed." << endl;
|
||||
PyErr_Clear();
|
||||
return false;
|
||||
}
|
||||
bool ret = bool_from_PyBool(result);
|
||||
if (!result)
|
||||
return -1;
|
||||
int ret = PyObject_IsTrue(result);
|
||||
Py_DECREF(result);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
// StrokeShader: shade
|
||||
void Director_BPy_StrokeShader_shade( PyObject *obj, Stroke& s) {
|
||||
int Director_BPy_StrokeShader_shade( PyObject *obj, Stroke& s) {
|
||||
PyObject *arg = BPy_Stroke_from_Stroke_ptr(&s);
|
||||
PyObject *result = PyObject_CallMethod( obj, "shade", "O", arg );
|
||||
Py_DECREF(arg);
|
||||
if (!result) {
|
||||
cerr << "Warning: StrokeShader::shade() failed" << endl;
|
||||
PyErr_Clear();
|
||||
return;
|
||||
}
|
||||
if (!result)
|
||||
return -1;
|
||||
Py_DECREF(result);
|
||||
return 0;
|
||||
}
|
||||
|
||||
// ChainingIterator: init, traverse
|
||||
void Director_BPy_ChainingIterator_init( PyObject *obj ) {
|
||||
int Director_BPy_ChainingIterator_init( PyObject *obj ) {
|
||||
PyObject *result = PyObject_CallMethod( obj, "init", "", 0 );
|
||||
if (!result) {
|
||||
cerr << "Warning: ChainingIterator::init() failed." << endl;
|
||||
PyErr_Clear();
|
||||
return;
|
||||
}
|
||||
if (!result)
|
||||
return -1;
|
||||
Py_DECREF(result);
|
||||
return 0;
|
||||
}
|
||||
|
||||
ViewEdge * Director_BPy_ChainingIterator_traverse( PyObject *obj, AdjacencyIterator& a_it ) {
|
||||
int Director_BPy_ChainingIterator_traverse( PyObject *obj, AdjacencyIterator& a_it, ViewEdge **ve ) {
|
||||
PyObject *arg = BPy_AdjacencyIterator_from_AdjacencyIterator(a_it);
|
||||
PyObject *result = PyObject_CallMethod( obj, "traverse", "O", arg );
|
||||
Py_DECREF(arg);
|
||||
if (!result) {
|
||||
cerr << "Warning: ChainingIterator::traverse() failed." << endl;
|
||||
PyErr_Clear();
|
||||
return NULL;
|
||||
if (!result)
|
||||
return -1;
|
||||
if (BPy_ViewEdge_Check(result)) {
|
||||
*ve = ((BPy_ViewEdge *) result)->ve;
|
||||
} else if (result == Py_None) {
|
||||
*ve = NULL;
|
||||
} else {
|
||||
PyErr_SetString(PyExc_RuntimeError, "traverse method returned a wrong value");
|
||||
Py_DECREF(result);
|
||||
return -1;
|
||||
}
|
||||
ViewEdge *ret = ((BPy_ViewEdge *) result)->ve;
|
||||
Py_DECREF(result);
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
// BPy_UnaryFunction{0D,1D}: __call__
|
||||
void Director_BPy_UnaryFunction0D___call__( void *uf0D, PyObject *obj, Interface0DIterator& if0D_it) {
|
||||
int Director_BPy_UnaryFunction0D___call__( void *uf0D, PyObject *obj, Interface0DIterator& if0D_it) {
|
||||
|
||||
PyObject *arg = BPy_Interface0DIterator_from_Interface0DIterator(if0D_it);
|
||||
PyObject *result = PyObject_CallMethod( obj, "__call__", "O", arg );
|
||||
Py_DECREF(arg);
|
||||
if (!result) {
|
||||
cerr << "Warning: UnaryFunction0D::__call__() failed." << endl;
|
||||
PyErr_Clear();
|
||||
return;
|
||||
}
|
||||
if (!result)
|
||||
return -1;
|
||||
|
||||
if( BPy_UnaryFunction0DDouble_Check(obj) ) {
|
||||
((UnaryFunction0D<double> *) uf0D)->result = PyFloat_AsDouble(result);
|
||||
@@ -204,18 +189,16 @@ void Director_BPy_UnaryFunction0D___call__( void *uf0D, PyObject *obj, Interface
|
||||
}
|
||||
|
||||
Py_DECREF(result);
|
||||
return 0;
|
||||
}
|
||||
|
||||
void Director_BPy_UnaryFunction1D___call__( void *uf1D, PyObject *obj, Interface1D& if1D) {
|
||||
int Director_BPy_UnaryFunction1D___call__( void *uf1D, PyObject *obj, Interface1D& if1D) {
|
||||
|
||||
PyObject *arg = BPy_Interface1D_from_Interface1D(if1D);
|
||||
PyObject *result = PyObject_CallMethod( obj, "__call__", "O", arg );
|
||||
Py_DECREF(arg);
|
||||
if (!result) {
|
||||
cerr << "Warning: UnaryFunction1D::__call__() failed." << endl;
|
||||
PyErr_Clear();
|
||||
return;
|
||||
}
|
||||
if (!result)
|
||||
return -1;
|
||||
|
||||
if( BPy_UnaryFunction1DDouble_Check(obj) ) {
|
||||
((UnaryFunction1D<double> *) uf1D)->result = PyFloat_AsDouble(result);
|
||||
@@ -251,6 +234,7 @@ void Director_BPy_UnaryFunction1D___call__( void *uf1D, PyObject *obj, Interface
|
||||
}
|
||||
|
||||
Py_DECREF(result);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -29,10 +29,10 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
// BinaryPredicate0D: __call__
|
||||
bool Director_BPy_BinaryPredicate0D___call__( PyObject *obj, Interface0D& i1, Interface0D& i2);
|
||||
int Director_BPy_BinaryPredicate0D___call__( PyObject *obj, Interface0D& i1, Interface0D& i2);
|
||||
|
||||
// BinaryPredicate1D: __call__
|
||||
bool Director_BPy_BinaryPredicate1D___call__( PyObject *obj, Interface1D& i1, Interface1D& i2);
|
||||
int Director_BPy_BinaryPredicate1D___call__( PyObject *obj, Interface1D& i1, Interface1D& i2);
|
||||
|
||||
// Interface0D: getX, getY, getZ, getPoint3D, getProjectedX, getProjectedY, getProjectedZ, getPoint2D, getFEdge, getId, getNature, castToSVertex, castToViewVertex, castToNonTVertex, castToTVertex
|
||||
double Director_BPy_Interface0D_getX( PyObject *obj );
|
||||
@@ -61,17 +61,17 @@ Id Director_BPy_Interface1D_getId( PyObject *obj );
|
||||
Nature::EdgeNature Director_BPy_Interface1D_getNature( PyObject *obj );
|
||||
|
||||
// UnaryFunction{0D,1D}: __call__
|
||||
void Director_BPy_UnaryFunction0D___call__( void *uf0D, PyObject *obj, Interface0DIterator& if0D_it);
|
||||
void Director_BPy_UnaryFunction1D___call__( void *uf1D, PyObject *obj, Interface1D& if1D);
|
||||
int Director_BPy_UnaryFunction0D___call__( void *uf0D, PyObject *obj, Interface0DIterator& if0D_it);
|
||||
int Director_BPy_UnaryFunction1D___call__( void *uf1D, PyObject *obj, Interface1D& if1D);
|
||||
|
||||
// UnaryPredicate0D: __call__
|
||||
bool Director_BPy_UnaryPredicate0D___call__( PyObject *obj, Interface0DIterator& if0D_it);
|
||||
int Director_BPy_UnaryPredicate0D___call__( PyObject *obj, Interface0DIterator& if0D_it);
|
||||
|
||||
// UnaryPredicate1D: __call__
|
||||
bool Director_BPy_UnaryPredicate1D___call__( PyObject *obj, Interface1D& if1D);
|
||||
int Director_BPy_UnaryPredicate1D___call__( PyObject *obj, Interface1D& if1D);
|
||||
|
||||
// StrokeShader: shade
|
||||
void Director_BPy_StrokeShader_shade( PyObject *obj, Stroke& s);
|
||||
int Director_BPy_StrokeShader_shade( PyObject *obj, Stroke& s);
|
||||
|
||||
// Iterator: increment, decrement, isBegin, isEnd
|
||||
void Director_BPy_Iterator_increment( PyObject *obj );
|
||||
@@ -80,8 +80,8 @@ bool Director_BPy_Iterator_isBegin( PyObject *obj );
|
||||
bool Director_BPy_Iterator_isEnd( PyObject *obj );
|
||||
|
||||
// ChainingIterator: init, traverse
|
||||
void Director_BPy_ChainingIterator_init( PyObject *obj );
|
||||
ViewEdge * Director_BPy_ChainingIterator_traverse( PyObject *obj, AdjacencyIterator& a_it );
|
||||
int Director_BPy_ChainingIterator_init( PyObject *obj );
|
||||
int Director_BPy_ChainingIterator_traverse( PyObject *obj, AdjacencyIterator& a_it, ViewEdge **ve );
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -217,14 +217,17 @@ PyObject * UnaryFunction0DDouble___call__( BPy_UnaryFunction0DDouble *self, PyOb
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj)) {
|
||||
cout << "ERROR: UnaryFunction0DDouble___call__ " << endl;
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj))
|
||||
return NULL;
|
||||
|
||||
if (self->uf0D_double->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it)) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf0D_double->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
double d = self->uf0D_double->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it));
|
||||
|
||||
return PyFloat_FromDouble( d );
|
||||
return PyFloat_FromDouble( self->uf0D_double->result );
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -160,13 +160,17 @@ PyObject * UnaryFunction0DEdgeNature___call__( BPy_UnaryFunction0DEdgeNature *se
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj)) {
|
||||
cout << "ERROR: UnaryFunction0DEdgeNature___call__ " << endl;
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj))
|
||||
return NULL;
|
||||
|
||||
if (self->uf0D_edgenature->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf0D_edgenature->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Nature::EdgeNature n = self->uf0D_edgenature->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it ));
|
||||
return BPy_Nature_from_Nature( n );
|
||||
return BPy_Nature_from_Nature( self->uf0D_edgenature->result );
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -189,13 +189,17 @@ PyObject * UnaryFunction0DFloat___call__( BPy_UnaryFunction0DFloat *self, PyObje
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj)) {
|
||||
cout << "ERROR: UnaryFunction0DFloat___call__ " << endl;
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj))
|
||||
return NULL;
|
||||
|
||||
if (self->uf0D_float->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf0D_float->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
float f = self->uf0D_float->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it ));
|
||||
return PyFloat_FromDouble( f );
|
||||
return PyFloat_FromDouble( self->uf0D_float->result );
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -160,13 +160,17 @@ PyObject * UnaryFunction0DId___call__( BPy_UnaryFunction0DId *self, PyObject *ar
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj)) {
|
||||
cout << "ERROR: UnaryFunction0DId___call__ " << endl;
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj))
|
||||
return NULL;
|
||||
|
||||
if (self->uf0D_id->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf0D_id->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Id id( self->uf0D_id->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it )) );
|
||||
return BPy_Id_from_Id( id );
|
||||
return BPy_Id_from_Id( self->uf0D_id->result );
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@@ -160,13 +160,17 @@ PyObject * UnaryFunction0DMaterial___call__( BPy_UnaryFunction0DMaterial *self,
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj)) {
|
||||
cout << "ERROR: UnaryFunction0DMaterial___call__ " << endl;
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj))
|
||||
return NULL;
|
||||
|
||||
if (self->uf0D_material->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf0D_material->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
FrsMaterial m( self->uf0D_material->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it )) );
|
||||
return BPy_FrsMaterial_from_FrsMaterial( m );
|
||||
return BPy_FrsMaterial_from_FrsMaterial( self->uf0D_material->result );
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -160,13 +160,17 @@ PyObject * UnaryFunction0DUnsigned___call__( BPy_UnaryFunction0DUnsigned *self,
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj)) {
|
||||
cout << "ERROR: UnaryFunction0DUnsigned___call__ " << endl;
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj))
|
||||
return NULL;
|
||||
|
||||
if (self->uf0D_unsigned->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf0D_unsigned->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
unsigned int i = self->uf0D_unsigned->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it ));
|
||||
return PyInt_FromLong( i );
|
||||
return PyInt_FromLong( self->uf0D_unsigned->result );
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -165,13 +165,17 @@ PyObject * UnaryFunction0DVec2f_getName( BPy_UnaryFunction0DVec2f *self )
|
||||
PyObject * UnaryFunction0DVec2f___call__( BPy_UnaryFunction0DVec2f *self, PyObject *args)
|
||||
{
|
||||
PyObject *obj;
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj)) {
|
||||
cout << "ERROR: UnaryFunction0DVec2f___call__ " << endl;
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj))
|
||||
return NULL;
|
||||
|
||||
if (self->uf0D_vec2f->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf0D_vec2f->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Vec2f v( self->uf0D_vec2f->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it )) );
|
||||
return Vector_from_Vec2f( v );
|
||||
return Vector_from_Vec2f( self->uf0D_vec2f->result );
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -160,13 +160,17 @@ PyObject * UnaryFunction0DVec3f___call__( BPy_UnaryFunction0DVec3f *self, PyObje
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj)) {
|
||||
cout << "ERROR: UnaryFunction0DVec3f___call__ " << endl;
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj))
|
||||
return NULL;
|
||||
|
||||
if (self->uf0D_vec3f->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf0D_vec3f->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Vec3f v( self->uf0D_vec3f->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it )) );
|
||||
return Vector_from_Vec3f( v );
|
||||
return Vector_from_Vec3f( self->uf0D_vec3f->result );
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -160,17 +160,20 @@ PyObject * UnaryFunction0DVectorViewShape___call__( BPy_UnaryFunction0DVectorVie
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj)) {
|
||||
cout << "ERROR: UnaryFunction0DVectorViewShape___call__ " << endl;
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj))
|
||||
return NULL;
|
||||
|
||||
if (self->uf0D_vectorviewshape->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf0D_vectorviewshape->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
std::vector<ViewShape*> vs( self->uf0D_vectorviewshape->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it )) );
|
||||
PyObject *list = PyList_New(NULL);
|
||||
|
||||
for( unsigned int i = 0; i < vs.size(); i++)
|
||||
PyList_Append(list, BPy_ViewShape_from_ViewShape(*( vs[i] )) );
|
||||
for( unsigned int i = 0; i < self->uf0D_vectorviewshape->result.size(); i++)
|
||||
PyList_Append(list, BPy_ViewShape_from_ViewShape(*( self->uf0D_vectorviewshape->result[i] )) );
|
||||
|
||||
return list;
|
||||
}
|
||||
|
||||
@@ -166,13 +166,17 @@ PyObject * UnaryFunction0DViewShape___call__( BPy_UnaryFunction0DViewShape *self
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj)) {
|
||||
cout << "ERROR: UnaryFunction0DViewShape___call__ " << endl;
|
||||
if(!PyArg_ParseTuple(args, "O!", &Interface0DIterator_Type, &obj))
|
||||
return NULL;
|
||||
|
||||
if (self->uf0D_viewshape->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf0D_viewshape->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
ViewShape *vs = self->uf0D_viewshape->operator()(*( ((BPy_Interface0DIterator *) obj)->if0D_it ));
|
||||
return BPy_ViewShape_from_ViewShape( *vs );
|
||||
return BPy_ViewShape_from_ViewShape( *(self->uf0D_viewshape->result) );
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -257,13 +257,17 @@ PyObject * UnaryFunction1DDouble___call__( BPy_UnaryFunction1DDouble *self, PyOb
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DDouble___call__ " << endl;
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
if (self->uf1D_double->operator()(*( ((BPy_Interface1D *) obj)->if1D )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf1D_double->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
double d = self->uf1D_double->operator()(*( ((BPy_Interface1D *) obj)->if1D ));
|
||||
return PyFloat_FromDouble( d );
|
||||
return PyFloat_FromDouble( self->uf1D_double->result );
|
||||
|
||||
}
|
||||
|
||||
@@ -271,10 +275,8 @@ PyObject * UnaryFunction1DDouble_setIntegrationType(BPy_UnaryFunction1DDouble* s
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DDouble_setIntegrationType " << endl;
|
||||
Py_RETURN_NONE;
|
||||
}
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
self->uf1D_double->setIntegrationType( IntegrationType_from_BPy_IntegrationType(obj) );
|
||||
Py_RETURN_NONE;
|
||||
|
||||
@@ -177,13 +177,17 @@ PyObject * UnaryFunction1DEdgeNature___call__( BPy_UnaryFunction1DEdgeNature *se
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DEdgeNature___call__ " << endl;
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
if (self->uf1D_edgenature->operator()(*( ((BPy_Interface1D *) obj)->if1D )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf1D_edgenature->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Nature::EdgeNature n = self->uf1D_edgenature->operator()(*( ((BPy_Interface1D *) obj)->if1D ));
|
||||
return BPy_Nature_from_Nature( n );
|
||||
return BPy_Nature_from_Nature( self->uf1D_edgenature->result );
|
||||
|
||||
}
|
||||
|
||||
@@ -191,10 +195,8 @@ PyObject * UnaryFunction1DEdgeNature_setIntegrationType(BPy_UnaryFunction1DEdgeN
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DEdgeNature_setIntegrationType " << endl;
|
||||
Py_RETURN_NONE;
|
||||
}
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
self->uf1D_edgenature->setIntegrationType( IntegrationType_from_BPy_IntegrationType(obj) );
|
||||
Py_RETURN_NONE;
|
||||
|
||||
@@ -170,13 +170,17 @@ PyObject * UnaryFunction1DFloat___call__( BPy_UnaryFunction1DFloat *self, PyObje
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DFloat___call__ " << endl;
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
if (self->uf1D_float->operator()(*( ((BPy_Interface1D *) obj)->if1D )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf1D_float->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
float f = self->uf1D_float->operator()(*( ((BPy_Interface1D *) obj)->if1D ));
|
||||
return PyFloat_FromDouble( f );
|
||||
return PyFloat_FromDouble( self->uf1D_float->result );
|
||||
|
||||
}
|
||||
|
||||
@@ -184,10 +188,8 @@ PyObject * UnaryFunction1DFloat_setIntegrationType(BPy_UnaryFunction1DFloat* sel
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DFloat_setIntegrationType " << endl;
|
||||
Py_RETURN_NONE;
|
||||
}
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
self->uf1D_float->setIntegrationType( IntegrationType_from_BPy_IntegrationType(obj) );
|
||||
Py_RETURN_NONE;
|
||||
|
||||
@@ -177,13 +177,17 @@ PyObject * UnaryFunction1DUnsigned___call__( BPy_UnaryFunction1DUnsigned *self,
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DUnsigned___call__ " << endl;
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
if (self->uf1D_unsigned->operator()(*( ((BPy_Interface1D *) obj)->if1D )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf1D_unsigned->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
unsigned int i = self->uf1D_unsigned->operator()(*( ((BPy_Interface1D *) obj)->if1D ));
|
||||
return PyInt_FromLong( i );
|
||||
return PyInt_FromLong( self->uf1D_unsigned->result );
|
||||
|
||||
}
|
||||
|
||||
@@ -191,10 +195,8 @@ PyObject * UnaryFunction1DUnsigned_setIntegrationType(BPy_UnaryFunction1DUnsigne
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DUnsigned_setIntegrationType " << endl;
|
||||
Py_RETURN_NONE;
|
||||
}
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
self->uf1D_unsigned->setIntegrationType( IntegrationType_from_BPy_IntegrationType(obj) );
|
||||
Py_RETURN_NONE;
|
||||
|
||||
@@ -183,13 +183,17 @@ PyObject * UnaryFunction1DVec2f___call__( BPy_UnaryFunction1DVec2f *self, PyObje
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DVec2f___call__ " << endl;
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
if (self->uf1D_vec2f->operator()(*( ((BPy_Interface1D *) obj)->if1D )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf1D_vec2f->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Vec2f v( self->uf1D_vec2f->operator()(*( ((BPy_Interface1D *) obj)->if1D )) );
|
||||
return Vector_from_Vec2f( v );
|
||||
return Vector_from_Vec2f( self->uf1D_vec2f->result );
|
||||
|
||||
}
|
||||
|
||||
@@ -197,10 +201,8 @@ PyObject * UnaryFunction1DVec2f_setIntegrationType(BPy_UnaryFunction1DVec2f* sel
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DVec2f_setIntegrationType " << endl;
|
||||
Py_RETURN_NONE;
|
||||
}
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
self->uf1D_vec2f->setIntegrationType( IntegrationType_from_BPy_IntegrationType(obj) );
|
||||
Py_RETURN_NONE;
|
||||
|
||||
@@ -177,13 +177,17 @@ PyObject * UnaryFunction1DVec3f___call__( BPy_UnaryFunction1DVec3f *self, PyObje
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DVec3f___call__ " << endl;
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
if (self->uf1D_vec3f->operator()(*( ((BPy_Interface1D *) obj)->if1D )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf1D_vec3f->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Vec3f v( self->uf1D_vec3f->operator()(*( ((BPy_Interface1D *) obj)->if1D )) );
|
||||
return Vector_from_Vec3f( v );
|
||||
return Vector_from_Vec3f( self->uf1D_vec3f->result );
|
||||
|
||||
}
|
||||
|
||||
@@ -191,10 +195,8 @@ PyObject * UnaryFunction1DVec3f_setIntegrationType(BPy_UnaryFunction1DVec3f* sel
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DVec3f_setIntegrationType " << endl;
|
||||
Py_RETURN_NONE;
|
||||
}
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
self->uf1D_vec3f->setIntegrationType( IntegrationType_from_BPy_IntegrationType(obj) );
|
||||
Py_RETURN_NONE;
|
||||
|
||||
@@ -191,17 +191,20 @@ PyObject * UnaryFunction1DVectorViewShape___call__( BPy_UnaryFunction1DVectorVie
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DVectorViewShape___call__ " << endl;
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
if (self->uf1D_vectorviewshape->operator()(*( ((BPy_Interface1D *) obj)->if1D )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf1D_vectorviewshape->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
std::vector<ViewShape*> vs( self->uf1D_vectorviewshape->operator()(*( ((BPy_Interface1D *) obj)->if1D )) );
|
||||
PyObject *list = PyList_New(NULL);
|
||||
|
||||
for( unsigned int i = 0; i < vs.size(); i++)
|
||||
PyList_Append(list, BPy_ViewShape_from_ViewShape(*( vs[i] )) );
|
||||
for( unsigned int i = 0; i < self->uf1D_vectorviewshape->result.size(); i++)
|
||||
PyList_Append(list, BPy_ViewShape_from_ViewShape(*( self->uf1D_vectorviewshape->result[i] )) );
|
||||
|
||||
return list;
|
||||
}
|
||||
@@ -210,10 +213,8 @@ PyObject * UnaryFunction1DVectorViewShape_setIntegrationType(BPy_UnaryFunction1D
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DVectorViewShape_setIntegrationType " << endl;
|
||||
Py_RETURN_NONE;
|
||||
}
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
self->uf1D_vectorviewshape->setIntegrationType( IntegrationType_from_BPy_IntegrationType(obj) );
|
||||
Py_RETURN_NONE;
|
||||
|
||||
@@ -192,12 +192,16 @@ PyObject * UnaryFunction1DVoid___call__( BPy_UnaryFunction1DVoid *self, PyObject
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DVoid___call__ " << endl;
|
||||
if( !PyArg_ParseTuple(args, "O!", &Interface1D_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
if (self->uf1D_void->operator()(*( ((BPy_Interface1D *) obj)->if1D )) < 0) {
|
||||
if (!PyErr_Occurred()) {
|
||||
string msg(self->uf1D_void->getName() + " __call__ method failed");
|
||||
PyErr_SetString(PyExc_RuntimeError, msg.c_str());
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
self->uf1D_void->operator()(*( ((BPy_Interface1D *) obj)->if1D ));
|
||||
Py_RETURN_NONE;
|
||||
}
|
||||
|
||||
@@ -205,10 +209,8 @@ PyObject * UnaryFunction1DVoid_setIntegrationType(BPy_UnaryFunction1DVoid* self,
|
||||
{
|
||||
PyObject *obj;
|
||||
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) ) {
|
||||
cout << "ERROR: UnaryFunction1DVoid_setIntegrationType " << endl;
|
||||
Py_RETURN_NONE;
|
||||
}
|
||||
if( !PyArg_ParseTuple(args, "O!", &IntegrationType_Type, &obj) )
|
||||
return NULL;
|
||||
|
||||
self->uf1D_void->setIntegrationType( IntegrationType_from_BPy_IntegrationType(obj) );
|
||||
Py_RETURN_NONE;
|
||||
|
||||
Reference in New Issue
Block a user