Forum News

Latest Prince builds can convert HTML to images

mikeday
To finish the year we have released a new latest build with an exciting feature: the ability to rasterise HTML documents directly to images!

Since the first release of Prince more than 12 years ago, we have focused on creating the best possible PDF output with CSS. But many customers have also requested bitmap image output for quick document preview in their applications.

Prince can now rasterise one page of the document to an image file, or create a separate image for each page. You can specify the DPI if you need higher resolution, and choose between fast JPEG output or accurate PNG output.

There are many other new features in the latest Prince builds:
  • CSS filters!
  • Helpful error messages for CSS syntax and property names!
  • A new control interface for high-throughput conversion!
And many other fixes and improvements to CSS, SVG, HTML, and JavaScript DOM.

We hope you give it a try! :D
skradel
First, apologies if replies to 'News' items aren't the proper place to ask questions.

Does "new control interface for high-throughput conversion" mean there will be new language wrappers available?
wachunga
Is the new control interface documented somewhere? Very interested in that feature.

Pulse Energy

mikeday
New server wrappers will be made available, starting with Java. (prince-java-20151110.zip)
joelmeador
I am also curious about documentation for the new control interface. Based on the java docs it sounds like it would be something DocRaptor wants. :D
jonno
This is great, rasterising directly from Prince is going to be a huge benefit for us. We've noticed that prince-cmyk colours are all coming through as black in raster outputs, is this a feature or bug?
mikeday
Rasterisation and SVG filters are RGB-only for the time being, but we may be able to do an approximate conversion from CMYK to RGB.
mikeday
The latest build of Prince supports color conversion for CMYK and other color spaces to sRGB for filtering and rasterisation.
vkzawa
I've made some SVG images that rely on the feGaussianBlur filter.
I've noticed they are working in the 20160810 build but my company is on 10r7 waiting for the next licensed release before they update Prince in our build script.

Do you have an idea of when filter rasterization feature will be available?
mikeday
It will be included in Prince 11, hopefully to be released before the end of this year. But the latest builds are usable right now. :)
mikeday
And Prince 11 is now available!
jonno
Thank you for the update! Will be road-testing this soon.