ICEpdf
  1. ICEpdf
  2. PDF-801

Optimization of get/set/Pixel() methods calls.

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 5.0.7
    • Fix Version/s: 5.1
    • Component/s: Core/Parsing
    • Labels:
      None
    • Environment:
      any

      Description

      As part of the work done for PDF-332 we moved our colour conversion algorithms out into the RasterOps package. The various routines use the raster.getPixel() and raster.setPixel() which are very slow at accessing the data.

      After doing some research is most more efficient way to get at the data is to access the DataBuffer's data array. Then go about the conversion as per usual.

      In my test on a rather large JPEG image 700x9900 the raster op procedure for converting YCbCr to RB went from about 4 seconds down to 350ms. Apply this logic across our Raster Ops and Image masking algorithms seems like a no brainer as we're looking at some pretty nice performance enhancements.

        Activity

        Hide
        Patrick Corless added a comment -

        QA finally passed and I think the optimizations are finally stable. The good news is that an 3 page QA run has gone from 21 minutes to just 12 minutes which is close to a 70% improvement. This a major improvement for our image loading.

        Show
        Patrick Corless added a comment - QA finally passed and I think the optimizations are finally stable. The good news is that an 3 page QA run has gone from 21 minutes to just 12 minutes which is close to a 70% improvement. This a major improvement for our image loading.
        Hide
        Patrick Corless added a comment -

        Update all of our methods. And we are looking at 30-40% improvement on our image decoding.

        Show
        Patrick Corless added a comment - Update all of our methods. And we are looking at 30-40% improvement on our image decoding.

          People

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

            Dates

            • Created:
              Updated:
              Resolved: