y-ssim support plus some other minor fixes.