MCPcopy Create free account
hub / github.com/FFmpeg/FFmpeg / wp_exp2

Function wp_exp2

libavcodec/wavpack.h:134–149  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

132extern const uint8_t ff_wp_log2_table[256];
133
134static av_always_inline int wp_exp2(int16_t val)
135{
136 int res, neg = 0;
137
138 if (val < 0) {
139 val = -val;
140 neg = 1;
141 }
142
143 res = ff_wp_exp2_table[val & 0xFF] | 0x100;
144 val >>= 8;
145 if (val > 31U)
146 return INT_MIN;
147 res = (val > 9) ? (res << (val - 9)) : (res >> (9 - val));
148 return neg ? -res : res;
149}
150
151static av_always_inline int wp_log2(uint32_t val)
152{

Callers 5

decorr_monoFunction · 0.85
decorr_stereoFunction · 0.85
decorr_stereo_quickFunction · 0.85
update_error_limitFunction · 0.85
wavpack_decode_blockFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected