Add text files support
Add ref-counted video buffers