Created by: philipnbbc
This PR adds an io_open option to av.open() which allows a client to provide a custom I/O. The io_open function is called with parameters url, flags, and options when a new file needs to be opened.
The existing file I/O was factored out into the PyIOFile class, with the addition of the fclose method. This class is used for the main file as well as for any files opened by the container.
Custom I/O has been used with the FFmpeg DASH encoder and could be used with containers that uses the io_open and io_close callbacks in the AVFormatContext. The test shows how it can be used with the DASH encoder by using a CUSTOM_IO_PROTOCOL prefix to direct the DASH encoder to use the custom I/O.