Here is the code I am using. Please look at it and sugest me if it can be improved further.
Kevin, I also tried what you suggested in the previous post. I calibrated the image but didn't correct and display it. Since I am drawing an overlay line for operator to use it as a reference for alignment I decided to correct the overlay line to impart the distortion it will haveif it were a straight edge on the FOV of the camera. I beleive I can succesfully calculate the distortion based on it's position on the screen. This method will be much faster since only hundred or less pixels are calculated for their real word positions. (However the overlay lines will have some curvature to it)
Unfortunately the customer is not buying this proposal yet. So I am still out looking for a solution to my real time image calibration issue. I am trying to attach two images of the calibration grid seen by right and left cameras each. When you down load the code you will have to correct the path for these files.
I am also wondering if developing this part of the code in LW/CVI will make it run faster. Since we are looking for at least 5 fps update from both cameras I would like for the calibration correction part of the code to finish within 150ms. Right now it is 320msec on the PC I mentioned on the orignal post.
Thanks