LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Pixel to array conversion (Vision toolkit)

Hello everybody,

 

I'm writing a vi to read out a CCD camera. I'd like to visualize the read out image converting one of its axis from pixels to other units (namely nm). I managed to do that by visualizing the image on an intensity graph creating accordingly a property node for the axis I wanted to convert . Is there a way to do this, so basically to convert one of the axis from pixels to a given array of values, using the vision toolkit?

 

Many thanks.

0 Kudos
Message 1 of 4
(2,463 Views)

Greetings, 

 

When you say that you are converting pixels to other units, do you mean that you know that certain number of pixels equals a certain number of nm? Basically, I just wanted to know a bit more about what you meant with the word convert.

 

If you would happen to mean convert to real world units, you might want to try the IMAQ Convert Pixel to Real World. VI. Then you would be able to measure distances with VIs such as the IMAQ Clamps  (such as IMAQ Clamp Horizontal.vi). 

 

Cordially;

National Instruments
Applications Engineer
0 Kudos
Message 2 of 4
(2,437 Views)

Hello,

 

Thanks for the reply.

 

The problem I've got to solve is the following. I have to read out a CCD camera. The light reaching the CCD is dispersed by a spectrometer. I know the algorithm to determine the correspondance between a given pixel of the camera and the wavelength of the light dispersed by the monochromator and reaching that pixel. I wrote a small VI (please find it attached) to obtain an array of values of wavelengths corresponding to each pixels, basically I can use the output of this small VI to know which are the minimum and maximum values of wavelength (in nm) displayed on the CCD camera and the increment in wavelength (in nm) correspondng to each pixel.  So if I display the read-out image using an intensity graph, I can use those values to create a property node for one axis of the graph and have it converted in the units I want (namely nm).

 

Now my question is: is there a way I can do the same using the output of my small conversion VI and one of the displaying options of the vision toolkit? The bottom line is: I'd like to use the vision toolkit vis instead than the intensity graph to display my images.

 

I hope my question is a bit clearer than before.

 

Many thanks for the help.

 

Cheers

 

0 Kudos
Message 3 of 4
(2,431 Views)

Greetings, 

 

I believe I understand your application better, I thank you kindly for the explanation. Would a VI such as the IMAQ Light Meter do the trick? It will allow you to measure the pixel intensities on a point or rectangle; there is a shipped example that shows how it may be used named Light Meter Example.

 

That particular example also finds out the max and min intensities, which is part of the application at hand.

 

Let me know if that helps!

 

Cordially;

National Instruments
Applications Engineer
0 Kudos
Message 4 of 4
(2,416 Views)