diff options
author | Justin Ruggles <justin.ruggles@gmail.com> | 2009-11-09 23:09:47 +0000 |
---|---|---|
committer | Justin Ruggles <justin.ruggles@gmail.com> | 2009-11-09 23:09:47 +0000 |
commit | b00803e0ae39cb785acd6128adb367bb4a8b7a0d (patch) | |
tree | df90ee8309cf632626c8e6eff05f706d0f318a5f /tests/tiny_psnr.c | |
parent | a7b9c8aefd52fdae8320b419e684415998b7c43a (diff) | |
download | ffmpeg-b00803e0ae39cb785acd6128adb367bb4a8b7a0d.tar.gz |
fix a rounding error in the PSNR calculation and update the many regression
test references that this change affects.
Originally committed as revision 20492 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'tests/tiny_psnr.c')
-rw-r--r-- | tests/tiny_psnr.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/tiny_psnr.c b/tests/tiny_psnr.c index 6327e6f9e4..f8d1b7bfa5 100644 --- a/tests/tiny_psnr.c +++ b/tests/tiny_psnr.c @@ -155,7 +155,7 @@ int main(int argc,char* argv[]){ if(!i) i=1; dev= int_sqrt( ((sse/i)*F*F) + (((sse%i)*F*F) + i/2)/i ); if(sse) - psnr= ((2*log16(max<<16) + log16(i) - log16(sse))*284619LL*F + (1<<31)) / (1LL<<32); + psnr= ((2*log16(max<<16) + log16(i) - log16(sse))*284619LL*F + (1LL<<31)) / (1LL<<32); else psnr= 1000*F-1; //floating point free infinity :) |