log

logarithm, y=16+8*log2(x)
Author: Johannes Taelman
License: BSD
Github: math/log.axo

IO Variants: 2


Variant: 1

Inlets

frac32.positive input

Outlets

frac32 output

Control Rate
Float_t f;
f.f = inlet_a;
int32_t r1 = ((f.parts.exponent & 0x7F) - 18) << 24;
int32_t r3 = logt[f.parts.mantissa >> 15] << 10;
outlet_result = r1 + r3;

Variant: 2

Inlets

frac32buffer.positive input

Outlets

frac32buffer output

Audio Rate
Float_t f;
f.f = inlet_a;
int32_t r1 = ((f.parts.exponent & 0x7F) - 18) << 24;
int32_t r3 = logt[f.parts.mantissa >> 15] << 10;
outlet_result = r1 + r3;

Privacy

© 2024 Zrna Research