Functions | |
| int | wv_log2i (int max_val) |
| Integer logarithm base 2 of a given integer. | |
| double | wv_mse_to_psnr (const double mse) |
| Converts MSE (mean square error) to PSNR (peak signal to noise ration (dB)). | |
| double | wv_psnr_to_mse (const double psnr) |
| Converts PSNR (peak signal to noise ration (dB)) to MSE (mean square error). | |
| double | wv_calc_psnr (const wv_pel *a, const wv_pel *b, const int width, const int height, const int pitch, double *pmse) |
| Computes the PSNR (peak signal to noise ratio (dB)) and optionally the mean-square error from two version of an image. | |
| int | wv_rgb_to_ycocg (const int Num, wv_pel *R, wv_pel *G, wv_pel *B) |
| Converts an array of pixels (given as seperate bitplanes) from the RGB color-space into the YCoCg color-space. | |
| int | wv_ycocg_to_rgb (const int Num, wv_pel *Y, wv_pel *Cb, wv_pel *Cr) |
| Converts an array of pixels (given as seperate bitplanes) from the YCoCg color-space into the RGB color-space. | |
| int | wv_rgb_to_ycocgr (const int Num, wv_pel *R, wv_pel *G, wv_pel *B) |
| Converts an array of pixels (given as seperate bitplanes) from the RGB color-space into the YCoCg-R color-space. | |
| int | wv_ycocgr_to_rgb (const int Num, wv_pel *Y, wv_pel *Cb, wv_pel *Cr) |
| Converts an array of pixels (given as seperate bitplanes) from the YCoCg-R color-space into the RGB color-space. | |
| double wv_calc_psnr | ( | const wv_pel * | a, | |
| const wv_pel * | b, | |||
| const int | width, | |||
| const int | height, | |||
| const int | pitch, | |||
| double * | pmse | |||
| ) |
Computes the PSNR (peak signal to noise ratio (dB)) and optionally the mean-square error from two version of an image.
| [in] | a | Image A |
| [in] | b | Image B |
| [in] | width | Width of the image in a and b |
| [in] | height | Height of the image in a and b |
| [in] | pitch | Pitch in wv_pel units of the image in a and b (usually this is a power of 2) |
| [out] | pmse | Address of a double where the mean-square error is written into (if != NULL) |
| int wv_log2i | ( | int | v | ) |
Integer logarithm base 2 of a given integer.
This is equal to the number of bits needed to encode that number.
| [in] | v | number whose log is wanted |
| double wv_mse_to_psnr | ( | const double | mse | ) |
Converts MSE (mean square error) to PSNR (peak signal to noise ration (dB)).
Inverse of wv_psnr_to_mse().
| [in] | mse | Mean square error |
| double wv_psnr_to_mse | ( | const double | psnr | ) |
Converts PSNR (peak signal to noise ration (dB)) to MSE (mean square error).
Inverse of wv_mse_to_psnr().
| [in] | psnr | Peak signal to noise ration (in dB) |
Converts an array of pixels (given as seperate bitplanes) from the RGB color-space into the YCoCg color-space.
Inverse of wv_ycocg_to_rgb().
| [in] | Num | Number of pixels to be converted |
| [in,out] | R | Red pixels on input, Y pixels on output |
| [in,out] | G | Green pixels on input, Co pixels on output |
| [in,out] | B | Blue pixels on input, Cg pixels on output |
Converts an array of pixels (given as seperate bitplanes) from the RGB color-space into the YCoCg-R color-space.
Inverse of wv_ycocgr_to_rgb(). This transform is reversible (i.e. lossless).
| [in] | Num | Number of pixels to be converted |
| [in,out] | R | Red pixels on input, Y pixels on output |
| [in,out] | G | Green pixels on input, Co pixels on output |
| [in,out] | B | Blue pixels on input, Cg pixels on output |
Converts an array of pixels (given as seperate bitplanes) from the YCoCg color-space into the RGB color-space.
Inverse of wv_rgb_to_ycocg().
| [in] | Num | Number of pixels to be converted |
| [in,out] | Y | Y pixels on input, red pixels on output |
| [in,out] | Co | Co pixels on input, green pixels on output |
| [in,out] | Cg | Cg pixels on input, blue pixels on output |
Converts an array of pixels (given as seperate bitplanes) from the YCoCg-R color-space into the RGB color-space.
Inverse of wv_rgb_to_ycocgr(). This transform is reversible (i.e. lossless).
| [in] | Num | Number of pixels to be converted |
| [in,out] | Y | Y pixels on input, red pixels on output |
| [in,out] | Co | Co pixels on input, green pixels on output |
| [in,out] | Cg | Cg pixels on input, blue pixels on output |
1.5.2