pub trait QualityPSNRTrait: QualityBase + QualityPSNRTraitConst {
    fn as_raw_mut_QualityPSNR(&mut self) -> *mut c_void;

    fn compute(&mut self, cmp: &dyn ToInputArray) -> Result<Scalar> { ... }
fn clear(&mut self) -> Result<()> { ... }
fn set_max_pixel_value(&mut self, val: f64) -> Result<()> { ... } }

Required methods

Provided methods

Compute the PSNR

Parameters
  • cmp: Comparison image
Returns

Per-channel PSNR value, or std::numeric_limits::infinity() if the MSE between the two images == 0

Implements Algorithm::clear()

sets the maximum pixel value used for PSNR computation

Parameters
  • val: Maximum pixel value

Implementors