Hello dear silky people :)<br>I&#39;ve thrown some code into the MediaCenter land and now it is possible to create simple video providers plugin for the video dataengine.<br>The video dataengine is supposed to provide an high level query &quot;api&quot; to retrieve video pieces of information from webservices like blip, vimeo, youtube and so on.<br>
<br>The little-but-working api i&#39;ve just started implementing works as follows:<br><br>A Plasma::DataEngine called &quot;video&quot; accepts queries in the following form:<br><br>[1] &quot;videoservice:searchTerm&amp;constaint1=value1&amp;constraint2=value2..&quot;<br>
<br>where &amp;constraints are optional (and currently not handled). Constraints are supposed to give filtering options when doing a query so that one can query the service with statements like:<br>&quot;I want a video of a Queen group&#39;s performance  with the keywords &quot;wembley&quot; and &quot;stadium&quot;, searched from YouTune&quot;. This would become &quot;youtube:queen&amp;keywords=wembley,stadium&quot; and should work as expected :).<br>
<br>The second possible type of query is more of internal purposes and is simply &quot;providers&quot;. This query returns the available plugins installed that provide the service to the video dataengine.<br><br>As already discussed with Marco on irc there was the need to keep the relation query &lt;-&gt; result in addition to also add new data sources to the dataengine. As from what we agreed the dataengine now works this way:<br>
<br>after the query a source is created named like searchTerm from [1]. This source will have the list of found videos ids as value.<br>In addition to this a source for each video id will be created. The name for each source will be the video id (as expected). The following values will then be provided for each video:<br>
<br> -   <b>QString id</b>: this is probably redundant.<br> -   <b>QString title</b>: the title of the video, no further explanation needed.<br> -   <b>QString description</b>: the description of the video as well.<br> -   <b>QString thumbnail</b>: an url to the thumbnail of the video. I decided to keep this as QString but suggestions are welcome of course.<br>
 -   <b>QStringList keywords</b>: the eventual list of keywords for this video.<br> -   <b>QString author</b>: the author of the video aka the one who published the video.<br> -  <b> uint duration</b>: the duration of course.<br>
 -   <b>QString category</b>: the eventual category of the video.<br> -   <b>QString embeddedHTML</b>: and this is probably the most interesting: the HTML code provided to embed the video in any web page. Since few video providers (probably only blip) give the chance to retrieve the real video file this is a sort of hack to retrieve the video and put it anywhere. Of course this would be accomplished using a QWebView to reproduce the video setting its html code to this one provided. Of course suggestions about this are really really appreciated.<br>
<br>This is what i achieved so far but suggestions for eventual additions to this list are also welcome.<br><br>The code is in the KDE&#39;s svn, exactly under trunk/playground/base/plasma/MediaCenterComponents<br>the video dataengine is under dataengines/video. In this folder you&#39;ll also find the videoprovider/ folder which hosts the plugin abstract class. The YouTube plugin is instead hosted under MediaCenterComponents/videoproviders/youtube.<br>
<br>Have a try and let me know :)<br><br>Cheers devs :p<br clear="all"><br>-- <br>Alessandro Diaferia<br>KDE Developer<br>