From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Colorful rectangle overlay on the grayscale image

Solved!
Go to solution

I am trying to create a rectangle overlay(preferably red), therefore I am using "IMAQ Overlay Rectangle" tool. But the overlay is nondestructive so I needed to use "IMAQ Merge Overlay" to overwrite on the image. However, after this tool output image is getting RGB format. I need grayscale image. Is there any way to overwrite colorful rectangle on the grayscale image. Thanks in advance, every suggestion is appreciated. 

0 Kudos
Message 1 of 3
(2,250 Views)
Solution
Accepted by oguzk

A grayscale image does not have any color.  The only way to add color is to convert it to a RGB image.  There is no way around it.

 

Bruce

Bruce Ammons
Ammons Engineering
0 Kudos
Message 2 of 3
(2,221 Views)

Thank you for the information. I thought maybe there is a build function for this but apparently there is no. Thanks.  

0 Kudos
Message 3 of 3
(2,211 Views)