From: James Courtier-D. <Ja...@su...> - 2002-10-17 13:23:43
|
There have been reports for some time about problems with the read cache code in libdvdnav. From the point of view of libdvdnav, it was never actually supposed to have a "get_next_block()" api call. The application using libdvdnav was supposed to do all the reading of sectors, and thus do their own caching. I propose that we therefore move the get_next_block() code from libdvdnav into "xine-lib/src/input/input_dvd.c" We can then implement a few standard read_cache methods that all input plugins can use. E.g. One read_cache method for internet based streams, and another for file based streams, and possibly another for dvd based streams. The only reason for a 3rd type for DVD streams, is that DVD have a bit more information that can help optimize the read_cache better than a file based stream. I think this would make writing good performing input plugins easier. I know that the current read_cache code in libdvdnav can be fixed and a patch is currently availiable to do it, but I still think that the job of read_caching should move to the input_plugin, and not happen in libdvdnav. Once the current stream_t CVS stabilises a bit, I will start this change, unless anyone thinks of a better idea, or thinks that there is no point to it. Cheers James |