LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to quickly add 150 images to a picture ring control

Background: I'm trying to animate  several eye candy items in a vi.  Inserting images as items in a picture ring has worked well for me so far (easy to control animation frame/image displaying with the vi.)

 

Is there a quick way to import 150 images into the items of a picture ring control (or picture ring indicator)?

The fastest way I've found so far is to drag 10 or so picture files onto the front panel at once.  Then select, copy (ctrl+c) and 'Import picture after' (right click on the picture ring) each image, one at a time.

Dragging and dropping each picture onto the picture ring one at a time does not seem to add them to the items in the picture ring.

 

I'm using Labview 8.5.

 

I know that I could draw each of the image files one at a time in a 2d picture.  But, I prefer to not deal with all the file I/O and I want the pictures to be stored in the vi, not as separate files.

 

Thanks for any help!

0 Kudos
Message 1 of 4
(3,391 Views)
There is no method I'm aware of for inserting the images into the ring automatically. You could probably hack the control and edit its binary data directly or automate mouse movements, but I would suggest you do use the picture control. If you want to avoid the disk I/O, read your images once into a 3D array using a for loop and then right click that indicator's terminal in the BD and select Change to Constant. This will embed all the image data in the VI.

___________________
Try to take over the world!
Message 2 of 4
(3,364 Views)
Would the cluster constant of images with the picture control be more processor/memory efficient than the picture ring of images?
0 Kudos
Message 3 of 4
(3,352 Views)

I don't have enough experience with the picture ring to be able to answer that. I can say that the picture control saves images as raster images with no compression, so that might take up more space if the picture ring can hold compressed images. In any case, if the picture is reasonably small, you should be fine. Just be sure to play with the right click options in the picture indicator (such as unchecking the Erase First option).

 

Another point is that earlier I suggested a 3D array (of pixels), but this will be simpler (and probably more efficient) if you use a 1D array of pictures instead.


___________________
Try to take over the world!
0 Kudos
Message 4 of 4
(3,337 Views)