Phil
Phil

Reputation: 666

Getting high quality pictures from dymola models

I need to get rather good images from my modelled objects from dymola. Taking a screenshot / using the snipping tool results in pictures with very poor quality due to the size of the models.

Is there a way to export the "pictures" i drew in dymola?

Upvotes: 3

Views: 635

Answers (2)

marco
marco

Reputation: 6655

The SVG export recommended by Rene Just Nielsen is not bad, but the models often don't look exactly as they do in Dymola, so I prefer the png export.

High resolution png images can be exported with the function exportDiagram.

 DymolaCommands.Documentation.exportDiagram(
   "C:/tmp/export.png", 
   width=2000, 
   height=2000,
   trim=true, 
   modelToExport="Modelica.Electrical.Analog.Examples.CauerLowPassSC");

Some notes about the function:

  • Very high resolutions, e.g. 4000x4000 pixels, take very long to export
  • If only file name is specified, the pics don't end up in the working directory but at top of the drive where the working directory is located
  • The function also exports svg files if a filename with the corresponding ending is chosen

Upvotes: 3

Rene Just Nielsen
Rene Just Nielsen

Reputation: 3413

You can export your model as an SVG image which is scalable and editable.

Best regards, Rene Just Nielsen

Upvotes: 5

Related Questions