I would like to implement a circular queue which grows and shrinks in size() dynamically for my application. When searching stack overflow for related threads, I came across this Simplified algorithm for calculating remaining space in a circular buffer? where MSN has mentioned about virtual streams.
Have anyone used this kind of indexing for circular queues ? Some background on this would help me implement this mechanism.