[IMAGING] PNG Component

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

[IMAGING] PNG Component

Sukant Kumar

Pull Request: https://github.com/apache/commons-imaging/pull/38

I have requested to merge the pull request before. This email is not
about that. I am happy that someone responded to my prior email
regarding how to get my PR merged. Anyways, I have added a commit again
to my fork (should I call it branch?). Here, I am going to discuss about
my new contribution on Dec. 1, 2018 (IST).

The PNG component used the ScanExpediter object to unfilter, and
un-interlace PNG image data and convert it into BufferedImage data. The
filtering logic was embedded in it, which is incorrect. Hence, I created
an object - AdaptiveFilter - which encapsulates the filtering logic. All
you do is feed it each scan-line serially, and it will filter/unfilter
the image data.

In addition, the PngWriter object now uses AdaptiveFilter to add
filtering functionality while writing PNG image data (before it only
used the NONE filter type, which was very inefficient). Now, the output
of PngMultipleRoundTest has 40-50% less size than the input PNG files in
data/images/png/3. I hope this will be appreciated.


Shukant Pal

To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]