I have a microscopy optical system that produces pincushion distortion largely along one axis, with the other being near perfect. I have evaluated this by imaging a fine square grid that fills the whole FOV. I can extract the centres of the grid squares and so produce an array of points that can be used to describe the distortion. I am unsure how to use these data to correct the original image. "undistortImage" from the Computer Vision Tlbx seems to depend up on "estimateCameraParameters" which in turn seems to require multiple images of a checkerboard taken at different positions and orientations. That doesn't seem to be the scenario I have in this case.
Additionally, I have the constraint that the correction needs to be applied as fast as possible. Ideally well under 100 ms.
Any suggestions gratefully appreciated.