LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I scale a JPEG image placed behind a graph control for precision alignment

Solved!
Go to solution

Hi

 

I need to scale an image in the form of a JPEG file and place behind a graph indicator. Placing an image is no problem but I cannot find a property node such as zoom that will allow scaling. This is the preferred method.

 

A second option could be to scale the plot size to that of the image, but this would have the drawback of not rescaling to different monitor screen resolutions.

 

Final option would be to record the desired data in a CSV file format and display both plots simultainiously, that I really do not want to do.

 

Any help would be appreciated.

 

Mike

0 Kudos
Message 1 of 9
(3,688 Views)

Hi MHR,

 

forth option:

use a picture indicator behind your plot to show the JPG. Here you have scaling factors available...

 

Could you show an example (picture) of what you really need?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 9
(3,676 Views)

Perhaps you can make something out combining these two examples 

\examples\picture\pictctl.llb\Picture Control - Zoom Attribute.vi 

\examples\general\graphs\Plot Images.vi

 



Besides which, my opinion is that Express VIs Carthage must be destroyed deleted
(Sorry no Labview "brag list" so far)
0 Kudos
Message 3 of 9
(3,668 Views)

Hi GerdW

 

I am not sure how to merge the pic control into the Graph, as putting it over the top will loose the actual plot function and graticule lines(Allthough the lines will be on the image too).

 

As for displaying the image seperately, the differencies are quite small and are not easily interpreted by the operator visually. That is why good registration is absolutely essential.

 

 

Mike

 

 

 

 

 

 

0 Kudos
Message 4 of 9
(3,658 Views)

Hi MHR,

 

I wrote "put behind" instead of your "merge"!

 

Create the pic indicator and put it behind the graph (make the graph background transparent...). There's a "Reorder" button in the menu of the vi front panel window! 

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 5 of 9
(3,649 Views)

Hi GerdW

 

I have searched all the prperty nodes for the waveform graph indicator and also XY graph indicator and cannot find anything that resembles the background other than BG Color which is set to 0 (Black).

 

I also could not find where on the front panel VI properties I set the Z order (or placing thing at front / back). On my example I simply placed the Graph on the front panel last covering most of the picture control.

 

Mike

0 Kudos
Message 6 of 9
(3,622 Views)

Take a look at my picture

 



Besides which, my opinion is that Express VIs Carthage must be destroyed deleted
(Sorry no Labview "brag list" so far)
Message 7 of 9
(3,611 Views)
Solution
Accepted by topic author MHR

Thanks

 

That works, however it means making the whole graph outline transparent, technically it will do, but presentation is not so good.

 

Thanks again

 

Mike

0 Kudos
Message 8 of 9
(3,604 Views)

Hi MHR,

 

"however it means making the whole graph outline transparent"

 

Well, that's what I meant when I wrote "put it behind the graph (make the graph background transparent...)"

 

"presentation is not so good"

In which way? This way you can make very nice frontpanels where the picture is fitting seamless into the graph! Remember: from LV8+ on you can also put a picture programmatically into the background of a graph (atleast into the plot area).

 

And, last but not least, please don't mark your own messages as solutions...

Message Edited by GerdW on 06-03-2009 03:21 PM
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 9 of 9
(3,590 Views)