LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

display images during raster image acquisition

Solved!
Go to solution

I am acquiring images by using a XY raster scan at the rate of between 10ms and 100ms per pixel. Hence for a 128x128 image, it might take over an hour to acquire the image. So far, I am only able to display the image once it has been acquired in entirety. Is there a way to add each new pixel to the image as it is collected and ideally change the grey scale in case part of the image becomes much brighter or darker during acquisition?

 

Thanks in advance

Chris

 

0 Kudos
Message 1 of 8
(565 Views)

Hi Chris,

 


@cghw wrote:

Is there a way to add each new pixel to the image as it is collected and ideally change the grey scale in case part of the image becomes much brighter or darker during acquisition?


Yes.

Spoiler
Fill your intensity graph inside the loop and not just once after the loop…

What have you tried and where are you stuck?

 


@cghw wrote:

scan at the rate of between 10ms and 100ms per pixel.

Hence for a 128x128 image, it might take over an hour to acquire the image


128×128×0.1s ~= 1640s, so less than half an hour… 😄

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 8
(557 Views)

Hi Gerd,

   thanks for the quick response. I attach some code snipped out from a larger project (hence the code - ScanXYDummy_1.vi - doesn't work on it's own). I am using the intensity graph to view the image. I have also explored IMAQ to see if there were possibilities there, but didn't find anything I thought I could use.

 

Thanks in advance.

Chris

 

0 Kudos
Message 3 of 8
(540 Views)

By the way, I forgot to mention that we also have some settling time delays in our acquisition, so the total time is quite a bit more than the number of pixels times the dwell time.

 

Thanks again

Chris

 

0 Kudos
Message 4 of 8
(539 Views)
Solution
Accepted by topic author cghw

Create a 128X128 array of zero values, and display it in an intensity graph.

Each time you get a new pixel, copy it over the array element in the correct (row, column) location.

Display the modified array in an intensity graph.

Repeat the second two steps until the image is complete.

You can set up the intensity graph to autoscale or use the max and min of the input pixel values to set the range each time you update a pixel value.

I usually use a gray scale map for intensity graphs.  You do not need IMAQ for display.

0 Kudos
Message 5 of 8
(521 Views)

Hi Chris,

 


@cghw wrote:

Hi Gerd,

   thanks for the quick response. I attach some code snipped out from a larger project (hence the code - ScanXYDummy_1.vi - doesn't work on it's own). I am using the intensity graph to view the image.


The "Electron count" graph needs to be placed and updated inside your loop when you want to show/see the updates!

 

Btw. when using an event structure then the event cases should be executed as fast as possible. When your "Start scan" event lasts for ~ one hour then you clearly violate this recommendation!

I recommend to use a QMH design (or even a simple state machine) instead…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 6 of 8
(497 Views)

Thanks john, your suggestion worked. I will try to figure out to mark the topic as solved.

 

Best Wishes

Chris

 

0 Kudos
Message 7 of 8
(481 Views)

Thanks Gerd, I will try to take on board your suggestions. The code was part of a larger program, so this might take a little while to implement !

 

Best Wishes

Chris

 

0 Kudos
Message 8 of 8
(479 Views)