mirror of
https://gitee.com/openharmony/third_party_ffmpeg
synced 2024-11-24 03:39:45 +00:00
avcodec/dcadec: use a constant instead of assuming every compiler can optimize pow(2,-15)
Idea-by: nevcairiel and wm4 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
6da06ef6bb
commit
9ccb5455ca
@ -2107,7 +2107,7 @@ static float dca_dmix_code(unsigned code)
|
||||
{
|
||||
int sign = (code >> 8) - 1;
|
||||
code &= 0xff;
|
||||
return ((dca_dmixtable[code] ^ sign) - sign) * pow(2, -15);
|
||||
return ((dca_dmixtable[code] ^ sign) - sign) * 0x1p-15;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user