dasp
dasp copied to clipboard
Offset phase in Signal
Hi, is it currently possible to offset the phase of a Signal (in dasp_signal
)?
For example, when defining a sine wave, how could I displace it by x rad?
signal::rate(sample_rate).const_hz(freq).sine()
If this has not yet been implemented, I'm happy to start a PR.
I tried using Phase.next_phase_wrapped_to
to accomplish this, but for some reason I could not get any signals created with the offset phase to generate anything but silence. I would love to see this supported!
I have started a PR #183