Revision 2d2fe557 tests/tiny_psnr.c
tests/tiny_psnr.c  

49  49 
195360063, 
50  50 
582360139072LL, 
51  51 
}; 
52 
#if 1 

53 
// 16.16 fixpoint exp() 

54 
static unsigned int exp16(unsigned int a){ 

55 
int i; 

56 
int out= 1<<16; 

57  
58 
for(i=19;i>=0;i){ 

59 
if(a&(1<<i)) 

60 
out= (out*exp16_table[i] + (1<<15))>>16; 

61 
} 

52  62  
63 
return out; 

64 
} 

53  65 
// 16.16 fixpoint log() 
54  66 
static int64_t log16(uint64_t a){ 
55  67 
int i; 
...  ...  
68  80 
return out; 
69  81 
} 
70  82  
83 
#endif 

71  84 
static uint64_t int_sqrt(uint64_t a) 
72  85 
{ 
73  86 
uint64_t ret=0; 
Also available in: Unified diff