1 | initial version |
Perhaps the easiest workaround would be to call waitKey less often. If you do it only every 4th or 5th frame, you should get back to your good frame rate.
Less easy would be to avoid calling waitKey and replace your ShowImage calls with something that draws without relying on the HighGui event loop.