Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8184429

Marlin rasterizer spends time computing geometry for stroked segments that do not intersect the clip

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 10
    • 8u131, 9
    • javafx

      We've noted before in principle that the Stroker in Marlin and Pisces both compute widened geometry for the entire path even if parts of it are so far outside the clip that they cannot affect rendering.

      Recently someone filed JDK-8183530 which demonstrates a real performance issue for AreaChart instances that have a huge list of data that is much wider than the graphed portion. Technically it is an issue that the AreaChart object maintains such huge path objects in the first place and it should subset the data to the visible portion when creating the Path objects to represent the chart, but it points out that the issue of time spent widening non-visible parts of a path is more than just a theoretical problem.

      See JDK-8183530 for a test case, though a standalone that just tests out-of-range stroking would be trivial to write.

        1. LineClipTest.java
          4 kB
          Laurent Bourgès
        2. Test.java
          2 kB
          Jim Graham

            lbourges Laurent Bourgès
            flar Jim Graham
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: