For instance I have some possible plans to replace the read thread with async IMFByteStream reads. I think we might want to keep track of outstanding read / sample requests, decrement the counters here and wait for them in the shutdown procedure.
What's the motivation for this?