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

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

Mutable methods for crate::quality::QualityPSNR

Required Methods§

Provided Methods§

source

fn compute(&mut self, cmp: &dyn ToInputArray) -> Result<Scalar>

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

source

fn clear(&mut self) -> Result<()>

Implements Algorithm::clear()

source

fn set_max_pixel_value(&mut self, val: f64) -> Result<()>

sets the maximum pixel value used for PSNR computation

Parameters
  • val: Maximum pixel value

Implementors§