Uploaded image for project: 'PDFBox'
  1. PDFBox
  2. PDFBOX-1924

Gouraud shading: detect empty triangles

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.8.4, 2.0.0
    • Fix Version/s: 1.8.5, 2.0.0
    • Component/s: None
    • Labels:
      None

      Description

      1) The ch14.pdf file has some empty triangles on p. 20, because two points of the triangle are identical. These empty triangles result in divide by zeroes, which can result in black raster coloring of a whole page at resolutions that I didn't use before.

      Bugfix: detect and delete empty triangles, and added code to detect an empty list and no background in GouraudShadingContext.getRaster().

      2) One statement (raster.setPixels) in GouraudShadingContext was accidentally moved one line up in the past which could result in lower performance.

        Attachments

          Activity

            People

            • Assignee:
              tilman Tilman Hausherr
              Reporter:
              tilman Tilman Hausherr
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: