Link

Why do some files display fractional white lines?

When converting PDF to HTML5 or SVG, you may notice a small subset of files where thin white lines appear in the generated output. Sometimes the white lines can be seen to a lesser extent in the original PDF file, and sometimes they may appear or disappear when zooming in or out.

1

Why are some PDF files like this?

This phenomenon is commonly seen in PDF files that were either produced by Adobe InDesign or compressed using Adobe’s PDF Optimizer/Compressor tools. Specifically, it is caused by the “transparency flattening” feature which works by cutting up the PDF content around areas of transparency and flattening those areas. We have also observed that this feature causes large images to be subdivided into smaller tiles regardless of transparency.

You can learn more about this here:

What causes the white lines?

When dividing the PDF content, the transparency flattening process adds a clip area around each of the subsections. This is done with very fine tolerances which creates a fraction of a pixel between the subdivisions that is outside the clip areas, thereby resulting in the appearance of thin lines between sections where those pixels are not being fully painted.

Why are the lines more prominent in BuildVu?

They occur more prominently in some PDF viewers due to differences in how graphics rendering engines paint pixels where content only partially overlaps them. The files that exhibit this issue are relying on a feature of PDF called Scan Conversion. Scan Conversion is a process controlled by the graphics renderer which determines how to paint a pixel when content only partially overlaps it.

The PDF specification calls for very forgiving scan conversion, to fully paint a pixel even when content only partially overlaps it. However converting to HTML and SVG means that we rely on the web browsers to render the content, which do not provide control of scan conversion.

Is there a workaround?

A workaround for this problem was added in the 2024.05.30 daily build. You can read more about it here: Thin Lines Improvement.


What's included in your BuildVu trial?

  • Access to download the SDK and run it locally.
  • Access to the cloud trial to convert documents in the IDR cloud.
  • Access to the Docker image to set up your own trial server in the cloud.
  • Communicate with IDR developers to ask questions & get expert advice.
  • Plenty of time to experiment and build a proof of concept.
  • Over 100 articles to help you get started and learn about BuildVu.
  • An exceptional PDF to HTML converter that took over 20 years to build!

Start Your Free Trial