# HG changeset patch # User Adam Stark # Date 1505201271 -3600 # Node ID e354bb51b875b6a18f78ecb4297a04c3c6346ee4 # Parent 6f5ba0250afd5ebe216833dc11e25b461753f75c Added some comments to CircularBuffer diff -r 6f5ba0250afd -r e354bb51b875 src/CircularBuffer.h --- a/src/CircularBuffer.h Tue Sep 12 01:00:53 2017 +0100 +++ b/src/CircularBuffer.h Tue Sep 12 08:27:51 2017 +0100 @@ -27,7 +27,8 @@ //======================================================================= /** A circular buffer that allows you to add new samples to the end * whilst removing them from the beginning. This is implemented in an - * efficient way which doesn't involve any memory allocation + * efficient way which doesn't involve any memory allocation as samples + * are added to the end of the buffer */ class CircularBuffer { @@ -62,6 +63,7 @@ writeIndex = 0; } + /** Returns the size of the buffer */ int size() { return static_cast (buffer.size());