GNOME Bugzilla – Bug 690533
SAMi(smi) subtitles support
Last modified: 2013-01-23 15:49:29 UTC
Created attachment 231943 [details] [review] a patch for smi subtitle support In Korea, SAMI(smi) type subtitles are widely used. It will be very useful if rygel detect smi subtitles.
Thanks, I will have a look. The subtitle implementation we carry currently is very specific for Samsung TVs, does it help you at all?
With this patch, I can see smi subtitles on my Samsung TV. I really need this feature :)
Review of attachment 231943 [details] [review]: Overall looking fine. ::: src/librygel-server/rygel-subtitle-manager.vala @@ +71,2 @@ + if (info.get_attribute_boolean (FileAttribute.ACCESS_CAN_READ)) { + var subtitle = new Subtitle ("text/plain", ext); We should probably query the CONTENT_TYPE in query_info above to use the correct content type (application/smil or application/x-srt or whatever) ::: src/librygel-server/rygel-video-item.vala @@ +88,3 @@ try { + var subtitles = subtitle_manager.get_subtitles (uri); + this.subtitles.add_all (subtitles); Did you test this with multiple subtitles? having a .srt and a .smi (not sure how likely that is, though) and check if it generates two resources?
Created attachment 233153 [details] [review] a patch for smi subtitle support
(In reply to comment #3) > Review of attachment 231943 [details] [review]: > > Overall looking fine. > > ::: src/librygel-server/rygel-subtitle-manager.vala > @@ +71,2 @@ > + if (info.get_attribute_boolean > (FileAttribute.ACCESS_CAN_READ)) { > + var subtitle = new Subtitle ("text/plain", ext); > > We should probably query the CONTENT_TYPE in query_info above to use the > correct content type (application/smil or application/x-srt or whatever) Ok, I uploaded a new patch. > > ::: src/librygel-server/rygel-video-item.vala > @@ +88,3 @@ > try { > + var subtitles = subtitle_manager.get_subtitles (uri); > + this.subtitles.add_all (subtitles); > > Did you test this with multiple subtitles? having a .srt and a .smi (not sure > how likely that is, though) and check if it generates two resources? I already tried to detect 2 subtitles, .srt and .smi. But my TV listed only one subtitle. Anyway, I think it is worth gathering all subtitles.
gathering all subtitles works, but for some reason only the first subtitle has the correct namespace.
Pushed slightly modified to fix the missing namespace issue
Thank you.