@@ -502,7 +502,8 @@ inline void RendererAgg::draw_markers(GCAgg &gc,
502502 agg::rgba color)
503503{
504504 typedef agg::conv_transform<py::PathIterator> transformed_path_t ;
505- typedef PathSnapper<transformed_path_t > snap_t ;
505+ typedef PathNanRemover<transformed_path_t > nan_removed_t ;
506+ typedef PathSnapper<nan_removed_t > snap_t ;
506507 typedef agg::conv_curve<snap_t > curve_t ;
507508 typedef agg::conv_stroke<curve_t > stroke_t ;
508509 typedef agg::pixfmt_amask_adaptor<pixfmt, alpha_mask_type> pixfmt_amask_type;
@@ -515,14 +516,16 @@ inline void RendererAgg::draw_markers(GCAgg &gc,
515516 trans *= agg::trans_affine_translation (0.5 , (double )height + 0.5 );
516517
517518 transformed_path_t marker_path_transformed (marker_path, marker_trans);
518- snap_t marker_path_snapped (marker_path_transformed,
519+ nan_removed_t marker_path_nan_removed (marker_path_transformed, true , marker_path.has_curves ());
520+ snap_t marker_path_snapped (marker_path_nan_removed,
519521 gc.snap_mode ,
520522 marker_path.total_vertices (),
521523 points_to_pixels (gc.linewidth ));
522524 curve_t marker_path_curve (marker_path_snapped);
523525
524526 transformed_path_t path_transformed (path, trans);
525- snap_t path_snapped (path_transformed, SNAP_FALSE, path.total_vertices (), 0.0 );
527+ nan_removed_t path_nan_removed (path_transformed, false , false );
528+ snap_t path_snapped (path_nan_removed, SNAP_FALSE, path.total_vertices (), 0.0 );
526529 curve_t path_curve (path_snapped);
527530 path_curve.rewind (0 );
528531
0 commit comments