Skip to content

Repeate Rendering in Polygon #4141

@HandsomeGoldenKnight

Description

@HandsomeGoldenKnight

Question:
In polygon rendering, rp.Canvas.DrawPath(path, paint); and Drawing.DrawLines(rp.Canvas, paint, pixels, LineStyle) seem to do the same thing. Is it OK to remove one of them?

ScottPlot Version: 5.0.37

Code Sample: https://github.com/ScottPlot/ScottPlot/blob/main/src/ScottPlot5/ScottPlot5/Plottables/Polygon.cs

if (LineStyle is { IsVisible: true, Width: > 0 })
{
    paint.Style = SKPaintStyle.Stroke;
    LineStyle.ApplyToPaint(paint);
    rp.Canvas.DrawPath(path, paint);
    Drawing.DrawLines(rp.Canvas, paint, pixels, LineStyle);
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions