Question

Can anyone explain me if is possible for the DLNA standard pass information of available external subtitles (.srt files) when playing media files (videos) without transcoding the video file.

If is possible then can anyone show me where this is explained in the DLNA standard? or how can this be implemented?

I'm trying to implement this using platinium library and don't know how to do it or if this is possible.

Thanks

Was it helpful?

Solution

Possible? Yes. Standardized? No. Reliable? Absolutely not. There is no specification of how to do subtitles right, neither in UPnP or DLNA. It ultimately is a question of how DMR wants the subtitles to be served by DMS, so it largely depends on the specific DMR you want to use. Some DMRs require a specific nonstandard DIDL-Lite field in media description (Samsung TVs seem to be promoting <sec:CaptionInfoEx>), some DMRs are happy with a somewhat standard-like <res protocolInfo="http-get:*:text/srt:*">. Both cases enclosing the URL of your SRT file, of course. It might be perfectly possible that your DMR does not support subtitles at all. There is no such requirement in either UPnP or DLNA (have i already said that?).

So Platinum does not have any subtitle support out of the box. You can create the <res> tag with existing logic - setting PLT_ProtocolInfo with ContentType of text/srt and assigning to PLT_MediaItemResource with m_Uri of your SRT file (served by your DMS).

Adding a new field is more tricky, PLT_Didl has a fixed set of fields which you must extend along with PLT_MediaObject::ToDidl which is pretty fixed in its operation. I consider this part of Platinum somewhat rushed, in comparison to the visible designing effort put in the rest of the framework.

In any case, your DMS must be also ready to act as HTTP server for your subtitles, which means giving the power to whatever class you have as implementation of PLT_MediaServerDelegate::ProcessFileRequest.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top