02-26-2009 05:24 PM
Hi,
I would like to combine interlaced image fields so that the resulting image has all fields (even and odd) populated. I could use CWIMAQVision.InterlaceSeparate to separate even and odd fields and the use CWIMAQVision.InterlaceCombine to fill the missing fields. I am afraid this will not give me the desired result, because the missing field are only replaced by the values in odd or even field. I would like to replace the missing field values with the interpolated values obtained from the fields above and below the missing field. Is there is way to accomplish this?
Regards.
Ekramul Majid
Solved! Go to Solution.
02-26-2009 08:19 PM
I would probably do the deinterlace, then use resample to double the Y resolution. The resample function uses interpolation to fill in the missing pixels. I'm not sure exactly what the resample function is called in CW.
Bruce
02-27-2009 11:04 AM
FYI, the resample function Bruce mentioned is CWIMAQVision.Resample2.
Greg Stoll
Vision R&D
National Instruments
02-27-2009 12:03 PM
Hi Greg,
Thanks for the reply. I tried but CWIMAQVision.Resample2 appears to be used for filling the missing fields when stretching the image. When used to produce an image of the original size, there was no effect.
Any other suggestions?
Ekramul Majid
02-27-2009 02:05 PM
Either I misunderstand what you are trying to do, or you missed a step. Here is my suggestion in more detail:
Start with an interlaced image 640x480.
Deinterlace to get an odd field (640x240) and an even field (640x240).
Pick a field and use resample to interpolate back to 640x480. This will double the Y dimension of the image.
Isn't that what you are asking for? If not, explain further what you are trying to do.
Bruce
02-27-2009 03:03 PM
Hi Bruce,
Thanks, it worked.
Ekramul