Bayley Wang
/
foc-ed_in_the_bot_compact
robot
Diff: Filter/Filter.cpp
- Revision:
- 147:c1b2379b8874
- Parent:
- 146:296bcc30e65d
- Child:
- 224:90172915d0fb
--- a/Filter/Filter.cpp Wed May 03 12:36:51 2017 +0000 +++ b/Filter/Filter.cpp Wed May 03 13:27:12 2017 +0000 @@ -3,7 +3,7 @@ #include "Filter.h" MedianFilter::MedianFilter(int length) { - buf = new CircularBuffer(length); + buf = new CircularBuffer(length, true); } float MedianFilter::update(float x) { @@ -12,7 +12,7 @@ } MovingAverageFilter::MovingAverageFilter(int length) { - buf = new CircularBuffer(length); + buf = new CircularBuffer(length, false); } float MovingAverageFilter::update(float x) {