• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  *  Copyright (c) 2014 The WebM project authors. All Rights Reserved.
3  *
4  *  Use of this source code is governed by a BSD-style license
5  *  that can be found in the LICENSE file in the root of the source
6  *  tree. An additional intellectual property rights grant can be found
7  *  in the file PATENTS.  All contributing project authors may
8  *  be found in the AUTHORS file in the root of the source tree.
9  */
10 
11 #ifndef VPX_INTERNAL_VPX_PSNR_H_
12 #define VPX_INTERNAL_VPX_PSNR_H_
13 
14 #ifdef __cplusplus
15 extern "C" {
16 #endif
17 
18 // TODO(dkovalev) change vpx_sse_to_psnr signature: double -> int64_t
19 
20 /*!\brief Converts SSE to PSNR
21  *
22  * Converts sum of squared errros (SSE) to peak signal-to-noise ratio (PNSR).
23  *
24  * \param[in]    samples       Number of samples
25  * \param[in]    peak          Max sample value
26  * \param[in]    sse           Sum of squared errors
27  */
28 double vpx_sse_to_psnr(double samples, double peak, double sse);
29 
30 #ifdef __cplusplus
31 }  // extern "C"
32 #endif
33 
34 #endif  // VPX_INTERNAL_VPX_PSNR_H_
35