10-23-2008 12:31 PM
Is is possible to write multiple .png images to a folder designated by a path?
I'm surprised I really haven't found any documentation about this.
What I am able to do is:
-capture a single .png image from a camera and save it to a folder
-run the camera in a video mode and view the video through a VI
I would basically like to run it in a video mode and capture each frame and save it as a .png file.
I'm not too familiar with LabVIEW, so please forgive my ignorance.
Solved! Go to Solution.
10-24-2008 11:28 AM
Hi jmeyer33,
You can designate a base path for your folder and then give each file a different relative path by using the Build Path VI. You can concatenate the filename and the Loop Iteration value from the while loop (converted to a string with Number to Decimal String) if you want each name to be the same except for a counter at the end (picture0.png, picture1.png, picture2.png, etc.).
Regards,
Stephen S.
10-28-2008 09:17 AM
Stephen (or others),
I am using the Build Path VI and the Number to Decimal String. However, the iteration is added to the very end of the base path. For example, "C:\Program Files\png_.png" becomes "C:\Program Files\png_.png\1" in the iteration. Is there a way to add the iteration in the middle of the path, such as "...\png_1.png", "...\png_2.png"?
Also, I have the appended path as input into an IMAQ Write File 2 VI. It doesn't seem to be writing the iterations though, perhaps because they have no extension (because they are ending up looking like "...\png_.png\1", "...\png_.png\2", and so on)? I don't know. Any suggestions would be greatly appreciated.
10-28-2008 10:48 AM