Hi Rui, > Hi, > > I think Elisa is the best media center solution I've seen. It's simple, > it has lots of nice plugins already, it's pretty and smooth. The only > thing that is missing it's the television support.
True, analog TV support was lacking until now. We are working on DVB support at the moment, it should be shipped with our next release. > I was browsing Elisa source code and noticed how small and simple the > plugins are. That encouraged me to try to add simple support to analog > television (that's what I have at home). > > So, I created a plugin named analogtv with two "elements": AnalogtvMedia > and V4l2Engine. > AnalogtvMedia was based on the youtube plugin. V4l2Engine was based on > PlaybinEngine. > > There's no sound/zapping/teletext support and video quality is poor, but > it's good enough to encourage me to improve it :) > They work for me in a machine running "Mythbuntu 8.04 Beta" with a > Pinnacle PCTV 110i tuner card and with trunk version of Elisa. Unfortunately I couldn't get my hands on a machine with a TV tuner card so I cannot test it properly, but it's good to know that you made it work with such little code. > AnalogtvMedia adds a new internet location in "Video -> Internet -> > Analog TV". Under this menu there's only 1 item "Tuner 1". > "Tuner 1" has uri "analogtv://video0" and a "real_uri" > "video:///dev/video0". > > V4l2Engine supports uri scheme video and for a given uri, like > "video:///dev/video0", it constructs the following pipeline > "v4l2src device=/dev/video0 always_copy=false ! (default videosink)" and > voila! > To, actually view something a channel as to be previously tunned, in > tvtime, for example. > > This was the first goal, put live video from the tuner in elisa screen. > > Problems that need to be solved: > - no sound support (current version linux-image in hardy repositories > is missing of saa7134-alsa driver. I'm wating for that to be resolved > before I can try anything). I imagine this is simple as placing a demux > in the pipeline and linking it to the audiosink. It should be, yes. > - no zapping. (there's a GstTuner > http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base-libs/html/gst-plugins-base-libs-gsttuner.html) > I imagine this is the way to go, together with a Controller or Input > Provider???. The channel list can be copied from another program's > channel configuration (like .tvtime/stationlist.xml, attached) Looks like the way to go, a GstTuner with an InputProvider. > - menu "Analog TV" placement. At the moment is under Video > Internet, > because it's automatically placed there when i send the message > InternetLocationMessage(action_type, "Analog TV", 'analogtv', uri, > media_types=['video'], theme_icon='television'). I've tried to send > MediaLocationMessage instead of InternetLocationMessage, but the menu > disapeared! This should be a simple thing, right? It could go under > Video, I think. That's the real issue with adding plugins at the moment, it's *really* not easy to integrate a menu item exactly where you want it. Clearly the analog TV entry should go under the Video menu. We are currently rewriting our architecture in depth (the new one being called the REST architecture) and that will make it much easier for contributors to integrate new elements and to write new views and smarter resource providers. > - no vbi (teletext). This is not really important, but it's a nice extra. > > Radio devices, like /dev/radio0, could be supported with this plugin > simply changing some names and disabling video in the pipeline. No? :) Sure, and that could go under another menu item and use the visualization as a video display. > If someone finds this plugin of any interest, please let me know and > send your suggestions and/or contributions. We're always interested in contributed code! If you want your code to be integrated in and shipped with Elisa, we need you to agree with our copyright assignment policy, see the document at http://elisa.fluendo.com/ca.pdf. Just a quick remark on your code: I noticed quite a lot of indentation inconsistencies. Other than that more documentation wouldn't harm, but seeing the state of the rest of the documentation I cannot really blame you! Documentation quality is one of our current efforts, and there's a lot of work ahead... As I was telling you above, we are currently rewriting our architecture and this implies API changes and plugins adaptations. The brand new architecture should be released in a month or so, in the meantime work on the current version in trunk is not lost, but be aware that it will require modifications to work with the new architecture. Of course we will provide documentation and support on this. > Rui Castro Cheers, Olivier
