ICEpdf
  1. ICEpdf
  2. PDF-684

Audit content parser for needless clipping commnds

    Details

    • Type: Task Task
    • Status: Closed
    • Priority: Major Major
    • Resolution: Won't Fix
    • Affects Version/s: 5.0.4
    • Fix Version/s: 5.0.5
    • Component/s: Core/Parsing
    • Labels:
      None
    • Environment:
      any
    • Salesforce Case Reference:

      Description

      We have a client that use ICEpdf for loading CAD drawings and they have seen varying performance from document to document. I've looked into this in the past and Java2D pipeline takes quite a performance hit if a complicated clip takes place. There are several places in our content parser where I think we are added extra/redundant clips to the pages shapes and this could responsible for rendering slow down on some complicated CAD pdf's.

      The client has attached two document, one that is created via a print using bullzip. The resulting PDF render significantly faster in ICEpdf then the original PDF.

        Activity

        Hide
        Patrick Corless added a comment -

        Samples added to support drive.

        Show
        Patrick Corless added a comment - Samples added to support drive.
        Hide
        Patrick Corless added a comment -

        I've taking a closer look at the PDF documents in question and the bullzip library does some very interesting things to the original file.

        original file: 188,629 shapes, ~1.95 MB
        bullzip file: 75,138 shpaes, ~3.0 MB

        As a result the bullzip file paints a lot faster as there are close to 2.5x less shapes to paint. Other notables are that the document outline tree is stripped from the output and the PDF version is downgraded from 1.6 to 1.5. My best guess is that is that the conversion is done using some virtual print device.

        Show
        Patrick Corless added a comment - I've taking a closer look at the PDF documents in question and the bullzip library does some very interesting things to the original file. original file: 188,629 shapes, ~1.95 MB bullzip file: 75,138 shpaes, ~3.0 MB As a result the bullzip file paints a lot faster as there are close to 2.5x less shapes to paint. Other notables are that the document outline tree is stripped from the output and the PDF version is downgraded from 1.6 to 1.5. My best guess is that is that the conversion is done using some virtual print device.
        Hide
        Patrick Corless added a comment -

        I've finished reviewing the content parser code to see if there is anyway to reduce the number of clips being set and unfortunately I couldn't find any hots spots. During the 5.0.0 release quite a few optimizations were made to the content parser including reducing the number of clips being applied.

        Show
        Patrick Corless added a comment - I've finished reviewing the content parser code to see if there is anyway to reduce the number of clips being set and unfortunately I couldn't find any hots spots. During the 5.0.0 release quite a few optimizations were made to the content parser including reducing the number of clips being applied.
        Hide
        Patrick Corless added a comment -

        After doing an analyses of the PDF in question there isn't much we can do to optimize the draw time of the original PDF document as there are just so many more shapes to paint when compared to the output of bullzip printed PDF document.

        Show
        Patrick Corless added a comment - After doing an analyses of the PDF in question there isn't much we can do to optimize the draw time of the original PDF document as there are just so many more shapes to paint when compared to the output of bullzip printed PDF document.

          People

          • Assignee:
            Patrick Corless
            Reporter:
            Patrick Corless
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: