[−][src]Function av_metrics::video::psnr::calculate_frame_psnr
pub fn calculate_frame_psnr<T: Pixel>(
frame1: &FrameInfo<T>,
frame2: &FrameInfo<T>
) -> Result<PlanarMetrics, Box<dyn Error>>
Calculates the PSNR for two video frames. Higher is better.
PSNR is capped at 100 in order to avoid skewed statistics from e.g. all black frames, which would otherwise show a PSNR of infinity.