diff options
author | Thomas Tsou <tom@tsou.cc> | 2013-11-09 22:19:19 -0500 |
---|---|---|
committer | Thomas Tsou <tom@tsou.cc> | 2013-11-15 23:35:07 -0500 |
commit | 94edaaeee653a03f6734782169f6ba3c042371e1 (patch) | |
tree | 7c2dd52ec46273db16adbd023db6a6bea03ebba7 /Transceiver52M/sigProcLib.h | |
parent | 0e0e1f43634cb6135f1620f97c84c9453325f005 (diff) |
Transceiver52M: Allow separate in/out vectors for delay and decimation
Allow non-in-place use of the delay setting. Internally, the delay call
creates a new vector and copies the contents back into the original.
Instead, provide the option to return the computed output vector
directly and remove an an extra copy in the process.
Signed-off-by: Thomas Tsou <tom@tsou.cc>
Diffstat (limited to 'Transceiver52M/sigProcLib.h')
-rw-r--r-- | Transceiver52M/sigProcLib.h | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/Transceiver52M/sigProcLib.h b/Transceiver52M/sigProcLib.h index 41bfdfb..4df7b3f 100644 --- a/Transceiver52M/sigProcLib.h +++ b/Transceiver52M/sigProcLib.h @@ -103,7 +103,7 @@ signalVector *modulateBurst(const BitVector &wBurst, float sinc(float x); /** Delay a vector */ -bool delayVector(signalVector &wBurst, float delay); +signalVector *delayVector(signalVector *in, signalVector *out, float delay); /** Add two vectors in-place */ bool addVector(signalVector &x, @@ -226,11 +226,10 @@ int analyzeTrafficBurst(signalVector &rxBurst, /** Decimate a vector. @param wVector The vector of interest. - @param decimationFactor The amount of decimation, i.e. the decimation factor. + @param factor Decimation factor. @return The decimated signal vector. */ -signalVector *decimateVector(signalVector &wVector, - int decimationFactor); +signalVector *decimateVector(signalVector &wVector, size_t factor); /** Demodulates a received burst using a soft-slicer. |