Hi. I am using NewImage to create an image plot of a 2D matrix using a Grays color table. In my code, I would like to go through each data point in the matrix and replot certain points as red that fall under a criteria I set. Is there some sort of plot point function where I can construct an image plot point by point in a for loop or a way to recolor a particular point in an image plot that was created using NewImage?
One approach is to display a combination of two images with one image effectively transparent except at a set of pixels that you set to red. You can find an example of this in the Image Processing Tutorial. Simply execute:
Hi.
The example in the help topic works, but when I apply it to my image, the overlay whites out the portions of the original image that I am overlaying on. So I get pixels highlighted in red and then just white everywhere else. This isn't the case when I run the example in the help topic. Modifying Image Appearance dialog box still shows that it's Grays LUT and changing scale doesn't do anything.
The example in the help topic works, but when I apply it to my image, the overlay whites out the portions of the original image that I am overlaying on. So I get pixels highlighted in red and then just white everywhere else.
If you are getting "white everywhere else" it suggests that you have not set the level of the pixels corresponding to your "everywhere else" to 64. For more information on that execute:
Modifying Image Appearance dialog box still shows that it's Grays LUT and changing scale doesn't do anything.
It kind of sounds like you are looking at the display parameters for your base image rather than for the overlay in the Modify Image Appearance dialog. At the top of that dialog is a drop down box titled "Image Wave". This shows the name of the image that the parameters apply to. Try clicking on the box and selecting the overlay wave.
You will need to modify "First Color at Z =", "Last Color at Z =" and "Before First Color", "After Last Color" for the overlay image, to get the overlay transparency correct.
One approach is to display a combination of two images with one image effectively transparent except at a set of pixels that you set to red. You can find an example of this in the Image Processing Tutorial. Simply execute:
DisplayHelpTopic "Overlays and Ornaments"
A.G.
WaveMetrics, Inc.
January 17, 2013 at 02:13 pm - Permalink
The example in the help topic works, but when I apply it to my image, the overlay whites out the portions of the original image that I am overlaying on. So I get pixels highlighted in red and then just white everywhere else. This isn't the case when I run the example in the help topic. Modifying Image Appearance dialog box still shows that it's Grays LUT and changing scale doesn't do anything.
Thanks
Satish
January 18, 2013 at 09:03 am - Permalink
If you are getting "white everywhere else" it suggests that you have not set the level of the pixels corresponding to your "everywhere else" to 64. For more information on that execute:
A.G.
WaveMetrics, Inc.
January 18, 2013 at 10:05 am - Permalink
It kind of sounds like you are looking at the display parameters for your base image rather than for the overlay in the Modify Image Appearance dialog. At the top of that dialog is a drop down box titled "Image Wave". This shows the name of the image that the parameters apply to. Try clicking on the box and selecting the overlay wave.
You will need to modify "First Color at Z =", "Last Color at Z =" and "Before First Color", "After Last Color" for the overlay image, to get the overlay transparency correct.
January 18, 2013 at 02:00 pm - Permalink