08-22-2011 01:07 AM
Hi everyone,
I was wondering if there is any way to perform mathematical operations on an IMAQ image, such as multiplication of the grey scale values by a constant or by their co-ordinates in the image.
I don't want to have to convert it to an array and use for loops, since this is very inefficient and may be the cause of some of the problems mentioned in my other thread.
Thanks!
08-22-2011 03:25 AM
yes, you have IMAQ functions for that :
If you want to multiply each pixel value by its coordinate I think you will have to code it yourself.
If you have IMAQ installed you can also go through the examples that come with it to see how to use these functions.
Another good source of information for image processing is the NI Vision Concept Manuel.
Hope this helps
We have two ears and one mouth so that we can listen twice as much as we speak.
Epictetus
08-22-2011 07:22 PM
Thanks, these IMAQ functions will be helpful, but the pixel co-ordinate operations are really what I was looking for.
When you say "you will have to code it yourself", does that mean I will have to use arrays and for loops anyway? Or is there some way to code for such operations on images?
Steve
08-23-2011 07:21 PM
You could create an image whose values are the coordinates (would presumably look like a ramp or gradient) and multiply that by your original image.
There are certainly many other things you can't do using the IMAQ functions, so if you want to support an easy way to do more, please tick this idea!