Printing diagrams blurs SVG Graphics [message #1848308] |
Sat, 27 November 2021 13:54  |
Bernhard Edler Messages: 6 Registered: August 2014 |
Junior Member |
|
|
Hi!
I'm using Sirius 6.5.0. Im my VSM i style my Nodes using SVG images as WorkspaceImages.
<nodeMappings name="Plankopf" domainClass="model::Plankopf">
<style xsi:type="style:WorkspaceImageDescription" labelSize="12" showIcon="false" labelExpression="""" hideLabelByDefault="true" sizeComputationExpression="-1" resizeKind="NSEW" workspacePath="/at.tb_gruber.designer.design/images/plankopf.svg">
<borderColor xsi:type="description:SystemColor" href="environment:/viewpoint#//@systemColors/@entries[name='black']"/>
<labelColor xsi:type="description:SystemColor" href="environment:/viewpoint#//@systemColors/@entries[name='black']"/>
</style>
</nodeMappings>
As you can see here, scaling works smoothly up to 400% zoom factor, as you would expect from SVG images.

But as soon as I export my design in any way (image, pdf, etc.), the SVG graphics get all blurry to a visible extent once printed on paper.

Any text, line shape etc. created by Sirius itself remains crisp when printed, apparently only my SVGs are scaled/rendered down. Is there any way I can manipulate the export that would result in correct print output?
best regards,
bernhard
Attachment: editor.png
(Size: 18.07KB, Downloaded 143 times)
Attachment: export.png
(Size: 17.58KB, Downloaded 147 times)
|
|
|
Re: Printing diagrams blurs SVG Graphics [message #1848349 is a reply to message #1848308] |
Mon, 29 November 2021 12:58  |
|
Hi.
This is a known limitation of the current graphics pipeline. SVG images displayed by Sirius at runtime are actually bitmap renderings (at the appropriate resolution) of the original vector file.
There is no other way really, Apache Batik is the only way we have to interpret the complex SVG spec, and it knows nothing about Eclipse-specific rendering APIs, so the only common ground is to make it render a bitmap and display that.
The result is that when we *export* a diagram, all images are taken from their bitmap/raster rendering on screen.
There might be a way to improve this in the case of SVG export, and we actually plan to look at it in the next few months, but it's too early to be sure if it will work and when it would be available.
Regards,
Pierre-Charles David - Obeo
Need training or professional services for Sirius?
http://www.obeodesigner.com/sirius
|
|
|
Powered by
FUDForum. Page generated in 0.01757 seconds