Discussion:
Treat picture as image
(too old to reply)
terwelu
2008-08-07 13:10:05 UTC
Permalink
Hi there, Is there any way to treat picture file (.jpg) as an image ?. I have some experience to "manipulate" my image (for instance, using edge detection, ROI, overlay, etc), but I find some difficulties to do that in picture. So, my idea is to "convert" my .jpg file into image. Is it possible ?terwelu
MikeS81
2008-08-07 13:10:07 UTC
Permalink
Hi terwelu,
do you use the vision toolkit?
Mike
terwelu
2008-08-07 14:10:06 UTC
Permalink
Hi Mike, Yeah, I think I have it with me. Is the vision toolkit contain of a bunch of image manipulation ? If yes, then what kind of tools should I use ?Tx Mike,terwelu
MikeS81
2008-08-07 14:10:10 UTC
Permalink
Hi terwelu,
if you have the vision toolkit, then you can load the image and work on it, with all available functions. I donĀ“t really understand what you mean with from picture to image in your first post. You can load a jpeg file without using the vision toolkit. You get a structure with all information you need.
Mike
muks
2008-08-07 14:40:10 UTC
Permalink
Hi terwelu,                 R u using LabVIEW for the first time and asking how to read an image file? do you want to read jpg without using vision tool kit?
corys
2008-08-07 14:40:06 UTC
Permalink
Hi terwelu,I apologize if this isn't what you're asking exactly, but is this what you're looking for when you mean changing from a picture to image? This VI (in the Graphics Formats palette) simply takes a .jpeg file and returns a cluster of 'image' data.<img src="Loading Image..."> Message Edited by corys on 08-07-2008 09:19 AM


readjpeg.PNG:
http://forums.ni.com/attachments/ni/170/347542/1/readjpeg.PNG
James McN
2008-08-07 15:40:05 UTC
Permalink
Hi Terwelu,
When you say you want to convert it to an image do you mean an imaq image so you can use vision toolkit VIs?&nbsp; If so then check out the files pallette under vision utilities, they allow you to load the standard file formats in and output them as an imaq image with a VI called IMAQ ReadFile.&nbsp; Hope this is what your after, if not let us know.
Regards,
terwelu
2008-08-08 09:40:11 UTC
Permalink
Thx in advance for all the guru's responses above. No, I'm not a new user in LabView but I'm still lacking of my knowledge in Image Processing. Sorry for unclear question, but here I attach more detail about how I defined and distinguished between "Image" and "Picture". In the top figure, the "Image" is represented as dark-purple line, while in the bottom side, the "Picture" is represented as blue line. Anyway, thx to James, I got your point and now I can solve my problem&nbsp;:smileyvery-happy: Long live the gurus !!! :smileywink:terwelu


Image&Picture.JPG:
Loading Image...
muks
2008-08-08 10:10:06 UTC
Permalink
<img src="Loading Image..." height="379" width="913"> So you have the vision tool installed.Still dont get it.R u stuck with some image opening function?
terwelu
2008-08-08 13:10:07 UTC
Permalink
Hi Muks, Sorry to make u got confused and no, I have no problem with image opening function. I just don't know until James told me. In my previous attachment, the top figure doesn't have any relation or case with the bottom figure. I created the top one several months ago with different case unlike the bottom one. But since I have a "small" experience in manipulating the image, I really don't want to deal with pictures. So, instead of manipulating the picture (I only have picture, not image), so I want to convert my picture into "single-shot" image (single frame only, not kind of movie). In my new figure (see attachment), I already change my top figure with image manipulation. You can see that in both figures in my attachment, I did the same rotating process. The different is, I did it with image function on top and with picture function on the bottom side. Hope this clear for you, Muks.terwelu<img src="file:///C:/DOCUME%7E1/RICKIY%7E1/LOCALS%7E1/Temp/moz-screenshot-3.jpg" alt="">


Same picture different method.JPG:
http://forums.ni.com/attachments/ni/170/347845/1/Same picture different method.JPG
DFGray
2008-08-08 14:10:07 UTC
Permalink
If you are doing image processing, you may want to consider a different format than JPEG, if that is possible.&nbsp; The JPEG compression process distorts the original image, resulting in changes to your image processing results.&nbsp; If you can get the image in either uncompressed or lossless compressed format, in general, you will get better results.&nbsp; The common uncompressed format is BMP.&nbsp; Common lossless compressed formats include PNG and TIFF (TIFF is supported by Vision, but is not native to LabVIEW).&nbsp; Note that your application may not need this, but it is something to think about.Message Edited by DFGray on 08-08-2008 08:52 AM
muks
2008-08-08 14:10:08 UTC
Permalink
f you are doing image processing, you may want to
consider a different format than JPEG, if that is possible.&nbsp; The JPEG
compression process distorts the original image, resulting in changes
to your image processing results.&nbsp; If you can get the image in either
uncompressed or lossless compressed format, in general, you will get
better results.&nbsp; The common uncompressed format is BMP.&nbsp; Common
lossless compressed formats include PNG and TIFF (TIFF is supported by
Vision, but is not native to LabVIEW).&nbsp; Note that your application may
not need this, but it is something to think about.
Totally agree.That too when you are into measurements and into microns,I feel it is better to maintain a safe distance from jpg..........
terwelu
2008-08-08 16:40:06 UTC
Permalink
Thx DFGray and Muks. With all respect to your advices, I'm not going into real advance measurement and microns this time. The manipulation for my image will be around doing some ROIs, overlay, rotate etc. Nevertheless, I really do appreciate your advice and I'll keep in my mind for my project in the future. terwelu :smileyhappy:
Loading...