Caution
This code does not work with OpenCV4, the most recent version of OpenCV that's installed on modern Linux. It requires an extensive rewrite to make it compatible.
Implementation of a structural similarity metric in C++ using OpenCV. Code from Philipp Klaus Krause updates to Rabah Mehdi original.
Resurrected to be a handy comparison with newer metrics particularly the Kornel Lesiński DSSIM tool.