mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-06-09 14:07:31 +02:00
avfilter/avf_showcwt: remove excessive operations
This commit is contained in:
parent
32a2268b6e
commit
a7a46aff46
@ -280,9 +280,7 @@ static void frequency_band(float *frequency_band,
|
|||||||
|
|
||||||
static float remap_log(float value, float log_factor)
|
static float remap_log(float value, float log_factor)
|
||||||
{
|
{
|
||||||
float sign = (0 < value) - (value < 0);
|
value = logf(value) * log_factor;
|
||||||
|
|
||||||
value = logf(value * sign) * log_factor;
|
|
||||||
|
|
||||||
return 1.f - av_clipf(value, 0.f, 1.f);
|
return 1.f - av_clipf(value, 0.f, 1.f);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user