UI Interest Group Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

Inserting images in to VI

I have a VI that I dressed up a bit. When I run it, the loop is about 10 times slower than without the images. Any idea on what is going on?

0 Kudos
Message 1 of 8
(9,250 Views)

Your background image means that UI nodes in front of it need to be completely redrawn when their data is updated.  Plus having the graph partially transparent is going to slow that down a lot too.  You could limit the image/UI control overlapping, and also maybe look at the "Defer Front Panel Updates" method, so your UI only updates when you need it to (eg: only once a second, rather than every time a data point is acquired).





Copyright © 2004-2024 Christopher G. Relf. Some Rights Reserved. This posting is licensed under a Creative Commons Attribution 4.0 License.
0 Kudos
Message 2 of 8
(3,635 Views)

So basically it is a bad idea to use images if you want a fast running VI that is constantly updating? I guess I'll run my VI without the images. Thanks for the reply.

0 Kudos
Message 3 of 8
(3,635 Views)

you can use the Front Panel Properties to insert your image in the background:

FP Properties.bmp

This should solve your problem.

If you place a Front Panel object on a drag&drop placed image, the image has to be reloaded every time the FP-object is updated. And thats why your VI is running slow with the images.

Sascha
0 Kudos
Message 4 of 8
(3,635 Views)

Simon posted a really good set of videos about creating UIs and even posted something about background images here:

http://decibel.ni.com/content/groups/ui/blog/2010/04/29/creating-quality-uis-with-ni-labview--develo...

There's also a "Campus Weather Monitor.vi" on the same post, look in the following file:

http://decibel.ni.com/content/servlet/JiveServlet/downloadBody/10241-102-1-16489/Creating%20User%20I...

0 Kudos
Message 5 of 8
(3,635 Views)

cheggers wrote:

you can use the Front Panel Properties to insert your image in the background:

FP Properties.bmp

This should solve your problem.

If you place a Front Panel object on a drag&drop placed image, the image has to be reloaded every time the FP-object is updated. And thats why your VI is running slow with the images.

The background was done that way. I also have opaque images used behind the plot indicator and the RPM indicator. I can only insert one image using the properties. Even the image added through the properties menu slows down the VI. The others I have to import to clipboard and place them on the front panel by dropping. This is the way Simon constructed his campus weather demo. I am guessing that it didn't matter since the refresh rate wasn't too fast.

0 Kudos
Message 6 of 8
(3,635 Views)

I use the method quite often as well, I create an image in gimp or paint.net that will over the entire background including logos, headers, etc. I then place all my controls over that and it works beautifully with no noticeable slowdown.

Gregory Osenbach
0 Kudos
Message 7 of 8
(3,635 Views)

…or right-click on the panel’s horizontal scroll bar for more static options.





Copyright © 2004-2024 Christopher G. Relf. Some Rights Reserved. This posting is licensed under a Creative Commons Attribution 4.0 License.
0 Kudos
Message 8 of 8
(3,635 Views)