LabVIEW Idea Exchange

cancel
Showing results for 
Search instead for 
Did you mean: 
scwimbush

Provide access to high resolution graph export

Status: New

When I print a front panel containing a graph (who ever does that?) I get a stunningly beautiful publication-quality render of my data (overlooking the poorly done vertical y-axis label). However, all the many options of directly exporting a graph image (detailed here) ultimately provide only a screen-resolution image. See the contrast in image quality below:

 

Printed front panel vs exported graph image.Printed front panel vs exported graph image.

This idea has been discussed ad infinitum on the forum (see, for example, here, here, herehere, and here), but has never been adequately resolved. (Enlarging the graph for export does not work since graph elements do not scale, so lines, points and labels end up being far too small.) High time to implement a feature that has been in demand since (at least) 2002!

17 Comments
wiebe@CARYA
Knight of NI

Any thoughts on the file\format of that export then?

scwimbush
Member

The existing options (.bmp when we Copy Data, or the "image data" returned by Get Image, which can then be converted to .jpeg, .png and .bmp), are all fine. I'm not asking for anything complex, just a high resolution (300/600 dpi instead of 72 dpi) export of the clearly available image data. Of course, the idea could be extended to an overhaul of the Export Simplified Image options, which provide for vector formats (.eps and .emf) that are not presently utilised. Or for full control, a "resolution" parameter could be added to the Get Image method.

thols
Active Participant

I'm afraid I know the answer will be: not in LabVIEW, use NXG. But I will add kudos.

 

The Print.Panel To Printer invoke node prints with high DPI, so you could try that, although it will only print to a printer and not an image. But it does not always do the same as the menu function, the graphics can be corrupted if I have something on top of the graph, in this case a string ("20") with custom graphics, which renders a black box on the graphics and the scale label:
graph print bug.PNG

Certified LabVIEW Architect
Broken_Arrow
Active Participant

The spirit of this Idea receives a big Kudos. This feature has not worked that well - it's just obtuse to write an Idea such as "Make this feature work better.."

Richard






thols
Active Participant

Just wanted to correct my previous post. The bug I mention happens with sub-panels. So "Print.Panel To Printer" can be used. But that only works for printing to printers. One way would be to install an image printer or a pdf printer to get that high image quality and then take that output file into LabVIEW again and embed it in your report. 

Certified LabVIEW Architect
scwimbush
Member

Thank you thols (and others). I had attempted the approach you describe, but experienced the same issue you mentioned in your first post, of regions of corruption appearing in the printed output. So I think this bug is present in more cases than just subpanels.

 

The best workaround I have been able to come up with to date is to use a dedicated VI and use the FP.Get Image Scaled method, which allows a higher resolution export, but only of the entire front panel, not of individual controls. So my original idea could be restated as adding a Get Image Scaled method to controls, instead of (as well as) the existing Get (low-res) Image method.

thols
Active Participant

Yes, "FP.Get Image Scaled" can work well in some cases. But it doesn't scale line thickness well or at all. Both plot lines and other graphic lines seems to always be thin. So I think one needs to test the best approach for each case to see what is most acceptable.

Certified LabVIEW Architect
pauldavey
Active Participant

There is the "Export Image" method that allows choosing EPS or EMF as the file format - doesn't that do what you want?

wiebe@CARYA
Knight of NI

AFAIK, Export Image just embeds a bitmap most of the times. So, it's not scalable.

pauldavey
Active Participant

I got a very nice vector image in EPS format. I am using LabVIEW 2019.