mediadevices
mediadevices copied to clipboard
Implement memory pool
As of now, the generic video/audio reader exposes release
function which lets the source to recycle the memory:
https://github.com/pion/mediadevices/blob/8dd84b269cd0d9ecaaf2e03863d7f1f15d94f99c/pkg/io/reader.go#L3-L15
However, to reuse the memory, we need to create a pool in the source which will get the memory back from the caller and reused by the source.