scale

Files: scale.h, scale.c

Bipolar Scale
This module scales from unipolar [0, 1] to another range defined by min and max.

Functions

sp_scale_create(sp_scale **scale)
sp_scale_init(sp_data *sp, sp_scale *scale)
sp_scale_compute(sp_data *sp, sp_scale *scale, SPFLOAT *in, SPFLOAT *out)
sp_scale_destroy(sp_scale **scale)

Optional Parameters

min: Minimum value to scale to.
(Default value: 0)
max: Maximum value to scale to.
(Default value: 1)

Inputs

in: Signal to be scaled.

Outputs

out: Scaled signal out