ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

2D Picture to Intensity Graph

Solved!
Go to solution

I have three 2D arrays of U8 representing red, green and blue components of an image. I can easily combine them into one 2D U32 array using "RGB to Color.vi" and display it as a picture (see attached VI). What I need though is to display the same image not as a picture, but as an intensity graph, with colors matching those of the picture (i.e. true RGB colors). How can I generate the color table for the intensity graph that would allow me to get the same image as a picture indicator using the same 2D U32 array as my data source? Thanks!

0 Kudos
Message 1 of 3
(5,359 Views)
Solution
Accepted by topic author Cepera

The Z-scale of the intensity graph is 8-bit, so the closest you can come is by converting the picture to 8-bit using Picture to Pixmap.vi and Unflatten Pixmap.vi.

 

RGB to Intensity Graph.png

 

Then you need to set the intensity graph so that it transposes the array (right-click option) and change the y-scale so it increases from the top (type 0 into the top marker and it will flip).

 

RGB to Intensity GraphFP.png

0 Kudos
Message 2 of 3
(5,348 Views)

Thanks Darin! I was missing the "8".

0 Kudos
Message 3 of 3
(5,338 Views)