@@ -310,12 +310,12 @@ static PyObject *Py_point_in_path_collection(PyObject *self, PyObject *args, PyO
310
310
numpy::array_view<const double , 3 > transforms;
311
311
numpy::array_view<const double , 2 > offsets;
312
312
agg::trans_affine offset_trans;
313
- int filled;
313
+ bool filled;
314
314
e_offset_position offset_position;
315
315
std::vector<int > result;
316
316
317
317
if (!PyArg_ParseTuple (args,
318
- " dddO&OO&O&O&iO &:point_in_path_collection" ,
318
+ " dddO&OO&O&O&O&O &:point_in_path_collection" ,
319
319
&x,
320
320
&y,
321
321
&radius,
@@ -328,6 +328,7 @@ static PyObject *Py_point_in_path_collection(PyObject *self, PyObject *args, PyO
328
328
&offsets,
329
329
&convert_trans_affine,
330
330
&offset_trans,
331
+ &convert_bool,
331
332
&filled,
332
333
&convert_offset_position,
333
334
&offset_position)) {
@@ -402,15 +403,16 @@ static PyObject *Py_clip_path_to_rect(PyObject *self, PyObject *args, PyObject *
402
403
{
403
404
py::PathIterator path;
404
405
agg::rect_d rect;
405
- int inside;
406
+ bool inside;
406
407
std::vector<Polygon> result;
407
408
408
409
if (!PyArg_ParseTuple (args,
409
- " O&O&i :clip_path_to_rect" ,
410
+ " O&O&O& :clip_path_to_rect" ,
410
411
&convert_path,
411
412
&path,
412
413
&convert_rect,
413
414
&rect,
415
+ &convert_bool,
414
416
&inside)) {
415
417
return NULL ;
416
418
}
@@ -527,20 +529,21 @@ static PyObject *Py_path_intersects_rectangle(PyObject *self, PyObject *args, Py
527
529
{
528
530
py::PathIterator path;
529
531
double rect_x1, rect_y1, rect_x2, rect_y2;
530
- int filled = 0 ;
532
+ bool filled = false ;
531
533
const char *names[] = { " path" , " rect_x1" , " rect_y1" , " rect_x2" , " rect_y2" , " filled" , NULL };
532
534
bool result;
533
535
534
536
if (!PyArg_ParseTupleAndKeywords (args,
535
537
kwds,
536
- " O&dddd|i :path_intersects_rectangle" ,
538
+ " O&dddd|O& :path_intersects_rectangle" ,
537
539
(char **)names,
538
540
&convert_path,
539
541
&path,
540
542
&rect_x1,
541
543
&rect_y1,
542
544
&rect_x2,
543
545
&rect_y2,
546
+ &convert_bool,
544
547
&filled)) {
545
548
return NULL ;
546
549
}
@@ -594,28 +597,30 @@ static PyObject *Py_cleanup_path(PyObject *self, PyObject *args, PyObject *kwds)
594
597
{
595
598
py::PathIterator path;
596
599
agg::trans_affine trans;
597
- int remove_nans;
600
+ bool remove_nans;
598
601
agg::rect_d clip_rect;
599
602
e_snap_mode snap_mode;
600
603
double stroke_width;
601
604
PyObject *simplifyobj;
602
605
bool simplify = false ;
603
- int return_curves;
606
+ bool return_curves;
604
607
SketchParams sketch;
605
608
606
609
if (!PyArg_ParseTuple (args,
607
- " O&O&iO &O&dOiO &:cleanup_path" ,
610
+ " O&O&O &O&O&dOO&O &:cleanup_path" ,
608
611
&convert_path,
609
612
&path,
610
613
&convert_trans_affine,
611
614
&trans,
615
+ &convert_bool,
612
616
&remove_nans,
613
617
&convert_rect,
614
618
&clip_rect,
615
619
&convert_snap,
616
620
&snap_mode,
617
621
&stroke_width,
618
622
&simplifyobj,
623
+ &convert_bool,
619
624
&return_curves,
620
625
&convert_sketch_params,
621
626
&sketch)) {
@@ -675,14 +680,14 @@ static PyObject *Py_convert_to_string(PyObject *self, PyObject *args, PyObject *
675
680
int precision;
676
681
PyObject *codesobj;
677
682
char *codes[5 ];
678
- int postfix;
683
+ bool postfix;
679
684
char *buffer = NULL ;
680
685
size_t buffersize;
681
686
PyObject *result;
682
687
int status;
683
688
684
689
if (!PyArg_ParseTuple (args,
685
- " O&O&O&OO&iOi :convert_to_string" ,
690
+ " O&O&O&OO&iOO& :convert_to_string" ,
686
691
&convert_path,
687
692
&path,
688
693
&convert_trans_affine,
@@ -694,6 +699,7 @@ static PyObject *Py_convert_to_string(PyObject *self, PyObject *args, PyObject *
694
699
&sketch,
695
700
&precision,
696
701
&codesobj,
702
+ &convert_bool,
697
703
&postfix)) {
698
704
return NULL ;
699
705
}
@@ -727,7 +733,7 @@ static PyObject *Py_convert_to_string(PyObject *self, PyObject *args, PyObject *
727
733
CALL_CPP (" convert_to_string" ,
728
734
(status = convert_to_string (
729
735
path, trans, cliprect, simplify, sketch,
730
- precision, codes, ( bool ) postfix, &buffer,
736
+ precision, codes, postfix, &buffer,
731
737
&buffersize)));
732
738
733
739
if (status) {
0 commit comments