Mark Stephens Mark Stephens has been working with Java and PDF since 1999 and has diversified into HTML5, SVG and JavaFX. He also enjoys speaking at conferences and has been a Speaker at user groups, Business of Software, Seybold and JavaOne conferences. He has a very dry sense of humor and an MA in Medieval History for which he has not yet found a practical use.

PDF to HTML5 conversion – non-rgb images

30 sec read

One of the strengths of the PDF file format is its support for lots of different colorspace types. It offers clever indexed modes and supports CMYK, DeviceN, Separation, Lab and other types of colour as well as gray, RGB and black/white. HTML5 still cannot match this range. So how do we handle all these color options?

One of the limitations of Java is that support for colorspaces beyond sRGB is rather limited. So luckily, we have already seen this issue and convert everything into sRGB for the PDF library. So images are converted into sRGB already…

The main issue with images then is that there are different ways to convert images depending on whether speed or precision is more important. I’ll cover that in another article…

Click here to see all the articles in the PDF to HTML5 conversion series.

IDRsolutions develop a Java PDF Viewer and SDK, an Adobe forms to HTML5 forms converter, a PDF to HTML5 converter and a Java ImageIO replacement. On the blog our team post anything interesting they learn about.

Mark Stephens Mark Stephens has been working with Java and PDF since 1999 and has diversified into HTML5, SVG and JavaFX. He also enjoys speaking at conferences and has been a Speaker at user groups, Business of Software, Seybold and JavaOne conferences. He has a very dry sense of humor and an MA in Medieval History for which he has not yet found a practical use.

Leave a Reply

Your email address will not be published. Required fields are marked *