Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9133843
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T08:33:23+00:00 2026-06-17T08:33:23+00:00

I’m trying to implement a simple DMS that can provide subtitle information to the

  • 0

I’m trying to implement a simple DMS that can provide subtitle information to the DMR -LG SmartTV – using platinium library.

I already succeeded to render video on the DMR and i already found where the DMR receive the information of the subtitle associated to the video file.

Sample request from the DMR:

    POST /upnp/services/ContentDirectory/control HTTP/1.1
HOST: 192.168.1.3:54444
CONTENT-LENGTH: 735
CONTENT-TYPE: text/xml; charset="utf-8"
SOAPACTION: "urn:schemas-upnp-org:service:ContentDirectory:1#Browse"
USER-AGENT: Linux/2.6.39.4.ps-110224-lg1152 UPnP/1.0 DLNADOC/1.50 INTEL_NMPR/2.0 LGE_DLNA_SDK/1.6.0

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/"
s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
  <s:Body>
    <u:Browse xmlns:u="urn:schemas-upnp-org:service:ContentDirectory:1">
      <ObjectID>ea06</ObjectID>
      <BrowseFlag>BrowseDirectChildren</BrowseFlag>
      <Filter>@id,@parentID,@restricted,@childCount,dc:title,dc:creator,upnp:artist,upnp:class,dc:date,upnp:album,upnp:genre,res,res@size,res@duration,res@protection,res@bitrate,res@resolution,res@protocolInfo,res@nrAudioChannels,res@sampleFrequency,upnp:albumArtURI,upnp:albumArtURI@dlna:profileID, res@dlna:cleartextSize</Filter>
      <StartingIndex>0</StartingIndex>
      <RequestedCount>24</RequestedCount>
      <SortCriteria></SortCriteria>
    </u:Browse>
  </s:Body>
</s:Envelope>

now the response from a valid DMS that support subtitle display is:

HTTP/1.1 200 OK
SERVER: WINDOWS/5.1 UPnP/1.0 DLNADOC/1.50 Nero-MediaHome/4.5.20.145
CONTENT-TYPE: text/xml; charset=utf-8
EXT:
DATE: Mon, 14 Jan 2013 22:12:35 GMT
TRANSFER-ENCODING: chunked
CONNECTION: Keep-Alive
...
          <item id="ea13" parentID="ea06" restricted="1">
            <dc:date>2012-10-25</dc:date>
            <dc:title>video.avi</dc:title>
            <upnp:album>Filmes</upnp:album>
            <upnp:class>object.item.videoItem.movie</upnp:class>
            <res 
              bitrate="257570" duration="1:37:32" nrAudioChannels="6" 
              protocolInfo="http-get:*:video/avi:DLNA.ORG_OP=01;DLNA.ORG_CI=0;DLNA.ORG_FLAGS=01700000000000000000000000000000" 
              resolution="720x304" sampleFrequency="48000" size="1507196928">http://192.168.1.3:54444/server/80402875-CA74-4CCE-B7E0-D81CEF1913A2/D5E59F25/ea13?unknown-id</res>
            <res protocolInfo="http-get:*:text/srt:*">http://192.168.1.3:54444/server/80402875-CA74-4CCE-B7E0-D81CEF1913A2/3A2C7131/ea13?sub=video.srt</res>
          </item>

Now i’m trying to implement the same in my custom DMS, can anyone point me in the right direction or show any sample that implements subtitle info stored in res element as: srt_URL (content-type of response is text/srt)

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T08:33:24+00:00Added an answer on June 17, 2026 at 8:33 am

    To add a SRT resource tag to UPnP item in Platinum, you should do at least the following. I don’t claim the list being functional, complete or tested. It’s just my best guess at what needs to be changed. If it doesn’t immediately work as expected, i may not be able to help you more specifically. It’s a navigation hint, not a driving assistance.

    • put your SRT file in the same folder as the media file, named the same way in some sensible way which would be easy for you to distinguish afterwards.
    • in PltMimeType.cpp add "srt","text/srt" to PLT_HttpFileRequestHandler_DefaultFileTypeMap. Platinum doesn’t know SRT out of the box.
    • PltFileMediaServer.cpp is kinda dumb, it by default shows up all files found in a directory. It’s an example, after all. You need to filter out SRTs from the visible listing by implementing PltFileMediaServer::ProcessFile filter.
    • still in PltFileMediaServer.cpp there is a method PLT_FileMediaServerDelegate::BuildFromFilePath. Here comes filepath which is the path of your media file (and ONLY that). Out of the filepath, you need to look in the folder whether there is a properly named subtitle file (with some NPT_File methods, look it up).
    • if there is, you must add extra PLT_MediaItemResource to the PLT_MediaObject* object. There is already one resource instance, but that’s used exclusively for the media resource itself. Don’t reuse it. You need to add another one, and IMO you need to set only resource.m_Uri (with BuildResourceUri) and resource.m_ProtocolInfo.
    • for m_ProtocolInfo, you need to call PLT_ProtocolInfo::GetProtocolInfo with parameter false so that the protocolInfo of your newly added <res> is not clobbered with DLNA profile id.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm new to using the Perl treebuilder module for HTML parsing and can't figure
I am trying to find ID3V2 tags from MP3 file using jid3lib in Java.
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I am doing a simple coin flipping experiment for class that involves flipping a
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
I'm trying to convert HTML to plain text. I get many &\#8217; &\#8220; etc.
I'm trying to create an if statement in PHP that prevents a single post
I'm making a simple page using Google Maps API 3. My first. One marker
I am trying to understand how to use SyndicationItem to display feed which is
Basically, what I'm trying to create is a page of div tags, each has

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.