02-15-2018 12:25 PM
Hello,
I have an intensity plot image that I want to save with cursor (without losing image quality) and having some issues. Can anyone point me where I'm doing wrong? I tried using overlay function to redraw cursor line in IMAQ but the coordinate is not right and the image size becomes 3 times bigger.
Thanks in advance.
Solved! Go to Solution.
02-15-2018 02:49 PM
Why do you create a new image? I would wire the original image into "IMAQ Overlay Line".
02-15-2018 03:45 PM - edited 02-15-2018 04:00 PM
Thanks for the reply. You are right, I could use the same image into overlay line. But I have to use the merge overlay.vi to save the line with the original image. However, that causes the image size to grow 3 times bigger.
Also, what would be a good way to convert that cursor position to IMAQ coordinate (start/end location used in overlay line.vi)?
Thanks.
02-15-2018 04:12 PM
This seemed to work, but the image looks rotated 90 degrees from the graph, but that's something you can look into.
Call overlay with the original image, merge, then cast it back to grayscale since merge returns RGB.
Hope this helps!
02-15-2018 06:37 PM - edited 02-15-2018 06:43 PM
Hi, thanks for the reply, that fixes the size issue. I don't have VDM installed (for IMAQ cast image vi), so I used pix map to convert to u8, I must be doing something wrong since the image came out is not right. Any suggestion is appreciated~!
Also, how can I convert the cursor position to imaq coordinate?
02-16-2018 09:01 AM - edited 02-16-2018 09:07 AM
Looks like you'll need to transpose then rebuild the 2-D array by swapping rows. The graph's cursor's coordinates are already referenced to the array's indices, so no scaling or offsetting is needed.