Mark Stephens Mark has been working with Java and PDF since 1999 and is a big NetBeans fan. He enjoys speaking at conferences. He has an MA in Medieval History and a passion for reading.

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.


Do you need to write or read JPEG in Java?

We have an easy guide on how to write JPEG in Java using ImageIO and JDeli. You can learn how to read/write most of the image files in ImageIO. However, it gives little control over the process.

JDeli is easy to use and offers complete support, so why don't you give a try?

Find out:

Mark Stephens Mark has been working with Java and PDF since 1999 and is a big NetBeans fan. He enjoys speaking at conferences. He has an MA in Medieval History and a passion for reading.

Leave a Reply

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

IDRsolutions Ltd 2020. All rights reserved.