phonon5 and the media sources

Harald Sitter sitter at kde.org
Sun Oct 20 13:54:38 BST 2013


On Sun, Oct 20, 2013 at 8:09 AM, Casian Andrei <skeletk13 at gmail.com> wrote:
>> I am wondering. Technically that is a SPU that might not be provided
>> by the source (e.g. subtitle-from-file), so right now I am actually
>> more inclined to say that is an effect applied to the player/output.
>> Though that may be confusing from an outside POV, not sure.
>
> What is a SPU?  Synergistic Processor Unit? :)

subpicture unit

>> > * The backends might be able to provide info about what kind of source
>> > is
>> > for a URL
>>
>> Not sure what you mean.
>
> You  give the backend an URL, and it sais - dude this is a DVD, or dude this
> is a hardware device, or dude this is a ordinary file. I think this is no
> longer valid with the new approach, since we assume the application always
> knows what's playing and won't try to control a microphone with a
> VideoSourceControl.

Ah, well, an application can choose to create nonsensical controls.
Calls to the control will do nothing though. But yeah there is no need
to ask phonon for the type of a URL. In fact it may not be even
interesting. What an application cares about are capabilities... does
it have video? if so, are subtitltes backed? if so, are there
subtitles to choose from?

> With this approach, is an application able to show menus specific for DVD's
> only when playing a DVD? Or buttons configuring subtitles only when playing
> videos? Or other things like this? It must know what kind of media it plays,
> but what if the developer is too lasy to implement such a thing? "I want my
> player to play everything and always know what's playing! Quickly, 1h
> development time!"
>
> Do we need to cover that use case?

See above, it's about the capabilities, not the media. So you could as
well create all controls under the sun, and then call various bool
foo() (isBacked and isActive supposedly) functions to see if doing
anything with that control made any sense, and then depending on that
show or hide GUI elements or at the very least populate them with
models etc..
And as I said, it's inherent to Sources that you know what is playing
from a container POV (is it a disc or a file or a remote stream or
whatever). Other than that the type does not matter, but the
capaibilities of a given Source.

That being said, keep in mind that with phonon4 you even have to know
the disc type to construct a MediaSource. So considering it worked out
fine in phonon4 I doubt we'll suddenly face unkown types in phonon5 ;)

HS



More information about the kde-multimedia mailing list