Skip to content

Conversation

@barafael
Copy link

@barafael barafael commented Jan 4, 2017

I do not know whether you actually use this filter, but I stumbled upon it and did 2 minor fixes.

  • Previously, the constructor parameter wasn't checked. The comment on top states that the buffer size can never be larger than MAF_ARRAYSIZE but this wasn't actually checked.

  • Less importantly, I speeded up the moving average calculation. For window sizes below 20 this didn't make a big difference, but for larger windows the new code still has roughly constant time while the old code takes more time with increasing buffer sizes. I wouldn't mind at all if you rejected this change, just let me know.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant