View Single Post
Posts: 1,203 | Thanked: 3,027 times | Joined on Dec 2010
#8
Not really. I was reworking the old cuteTube widget based UI and implementing something similar to what you have in terms of interpreting the command line. The initial plan was to see if I could make it so that it could one day be a plugin for cuteTube1 but the handling of streams vs console output prevented it going much further.

IIRC I was adapting some of the python code from giPlayer. Managed to get searching, displaying the episode description and thumbnail, related search (just searches by series name) and viewing by category (now unsupported by get_iplayer). Transfers were working in the previous iteration before I started refactoring everything to be more independant of cuteTube framework.

I must say your code does appear to be a lot cleaner than my version. I don't have the code handy as its on the laptop. I do seem to remember the metadata was returned by submitting --listformat along with what you want in the order you want it, including the thumbnail location, which was then obtained via a cache. If the file was not in the cache a placeholder was set until the image was downloaded, like https://github.com/marxoft/cutetube2...imagecache.cpp

Might be worth looking --expiry at some stage. If cache is older than 4hrs iirc it will automatically redownload the cache when get_iplayer is run. This might be undesirable if trying to download a show in your current >7 day old cache as the refresh might cause the information to be removed from your local db. Secondly, depending on data tariff it might not be desirable. Lastly if there is no internet connection it will probably wipe out the existing cache meaning you can't view or search anything.

With regards to episode length, unless things have changed, the values stored in the local db/cache are pretty useless (ie 0) and are only rough estimates when doing a full metadata retrievel via --info (ie 30, 45, 60mins etc.)

I have done some experiments with live streaming via ffplay, the code is somewhere in the get_iplayer and rtmpdump thread. If your running a recent ffmpeg with librtmp support you could also stream the DASH audio for the radio stations.

When I get a bit of time I might take another look at it. Think I need an update to rtmpdump first to fix progress % being messed up. Might take some cues from your output parsing to clean my code up a bit.

With regards to packaging the perl modules, all I can suggest is to look at Jollas existing spec files for other packages. XML::Simple is now required, which is what I still need to push to fix Maemo versions of get_iplayer. The minimum perl requirement is lower than what they suggest but on Sailfish I suspect it's newer than Maemo anyway.

Feel free to PM if I can help at all.