Continuing my last year’s GSOC, finally I managed to implement support for importing embedded raster images in libwpg. As with other graphics formats such as SVG, PDF, and ODG, WPG allows pixmaps or images to be combined with the vector graphics. It was a bit difficult because raster images are typically compressed using RLE (run-length encoding) and it was not too trivial to decode it. And I still do not code all possible depth/format yet. But finally, here is the mandatory click-to-enlarge screenshot:
Left is the original WPG which I made in Corel Presentations by placing this beautiful windmill in Bremen together with a windmill picture from the clip art. Right is the WPG file opened and showed in Perfectspot (the all-around WPG viewer and converter).
Note that I’m waiting for Qt 4.3 before making a first stable release of Perfectspot (and also libwpg, provided that all image loading support is good enough). The reason is because it needs ObjectBoundingMode for QGradient which really simplifies the code. That’s why, in the above screenshot, the gradient is not yet properly rendered in Perfectspot.
In related story, thanks to our very own Master Fridrich, libwpg-based WPG importer is going into ooo-build. So at least the next version of Novell’s OpenOffice.org will be able handle those WPG files.