Emulating LG Smart Share behavior

For help and support with Universal Media Server
Forum rules
Please make sure you follow the Problem Reporting Guidelines before posting if you want a reply
Post Reply
johnrom
Posts: 3
Joined: Sun May 07, 2023 12:42 am

Emulating LG Smart Share behavior

Post by johnrom »

Features of LG Smart Share I'd like to emulate with UMS:

- No transcoding of audio or video, if it plays it plays. If UMS transcodes the media I can't fast forward or rewind the video and I can't pause it. Or rather can't successfully unpause it.
- Make text subtitle files, SRT for eg, available to the TV when they're named the same as the video file. The TV sees it as a separate file since it's possible to turn the subtitles on or off in the TV video player. I don't care which language is the audio, I don't care in which language UMS thinks the subtitles are - if a subtitles file with the same filename is present make it available!

Is it possible to achieve this in UMS?

I'm obviously using a WebOS LG TV. I tried a lot of combinations of language settings, forcing subtitles, etc. I know about the chapter workaround for seeking over transcoded video, I'm not a fan.

I can't quite remember why I can't use the LG Smart Share, it's probably some stability issue, and in the end I would very much like to use UMS for all of its advanced features. But I need to have these baseline requirements sorted first! So before we get into the details, with this asking me to press I button I don't see, before I ask why are there both two and three letter country code standards used on the same settings page and if it matters which one I use and why UMS keeps thinking Serbian subtitles are in Czech I would just like to know if my goal is possible. Thank you!
User avatar
mik_s
Moderator
Posts: 1115
Joined: Wed Aug 23, 2017 11:03 pm
Location: UK

Re: Emulating LG Smart Share behavior

Post by mik_s »

UMS already does that but it depends on the capabilities of the renderer.

There are many types of LG TV that use WebOS and not all have the the same format support. If UMS thinks a renderer does not support the format of the video you are playing then it will transcode it to one that will, but has the downside of being unable to seek because as transcoding is happening in real-time the renderer cannot move to a part of the video that does not exist yet depending on the method used to seek.

Try using the conf from here to see if it works better for you.

One way to see if a format is supported without UMS transcoding it is to play from the #--TRANSCODE--# folder and choose "No transcoding"
(if you do not see it, enable "show the #--Transcode--# folder" in the GUI on the navigation tab, in the web GUI it is in the "virtual folders/files" section)
If it plays without issue but is transcoded when not playing normally then the conf will need to be tweaked.

When a video is streamed then the renderer has to handle all the subs. If a subtitle file is in the same folder as the video then it will be sent as an extra source if it is requested, but again it depends on the renderer and if the video already has embedded internal subtitles it may get ignored.

I'm not sure about the language codes, I think it should be 3 letters but is something I have not needed to use myself. As to why UMS thinks Serbian subtitles are in Czech I would need to see the logs.

Any specific problems with some videos I will need to see logs to see what is happening. The red section above refers to the old java GUI and could do with a update for the web GUI. You can still open the old settings by right clicking the tray icon and select "settings (old)"
Logs are important for us to help, Please follow This Link before asking for support. Just a forum cleaner, Will help if I can but no expert.
johnrom
Posts: 3
Joined: Sun May 07, 2023 12:42 am

Re: Emulating LG Smart Share behavior

Post by johnrom »

mik_s wrote: Sun May 07, 2023 3:10 amTry using the conf from here to see if it works better for you.
This solved everything! Thank you! I'll figure out why at some point and let everyone know. One of the reasons why this is so frustrating to me is that the server PC and TV are in distant rooms, so trial and error becomes trial, hiking and error. :)
mik_s wrote: Sun May 07, 2023 3:10 amOne way to see if a format is supported without UMS transcoding it is to play from the #--TRANSCODE--# folder and choose "No transcoding"
Side note and suggestion: include a "menu" item in the Transcode "folder" - "Previous no transcode played okay". When selected UMS should add the media attributes to the "whitelist" in the renderer conf file. That way users who do want to use transcoding could more quickly and easily build up the list, instead of digging through conf specs, various acronyms, codec names etc. A "did not play okay" should also be possible, but more difficult to implement.
mik_s wrote: Sun May 07, 2023 3:10 amYou can still open the old settings by right clicking the tray icon and select "settings (old)"
I am using Settings (old), I just don't see the "Create TRACE logs" button. :)
ums logs.png
ums logs.png (82.12 KiB) Viewed 1240 times
User avatar
mik_s
Moderator
Posts: 1115
Joined: Wed Aug 23, 2017 11:03 pm
Location: UK

Re: Emulating LG Smart Share behavior

Post by mik_s »

You have UMS in TRACE mode already so that button turns to "Pack Debug Files". This will pack the logs, settings and confs used into a zip file you can post.

The supplied WebOS.conf errs on the side of having everything being able to play on all LG TVs, even if it is transcoded, than to have some TVs not being able to play some of them because they do not support that format or support was removed.
One example is newer TVs are removing the ability to play DTS audio so the manufacturer does not need to pay for the licence. I think LG did this too.

It is far better to get the conf right to play your videos than to create a whitelist.
You might have hundreds of videos in a format that can be streamed but is not defined in the conf and it wold not be practical to go though them all to add to the list.
Also the confs can not be changed by UMS (would need admin privileges) and they would be overridden when UMS is updated.
It could be possible to store that in the database but that would also apply for other devices if you use UMS on them. It would also take quite a bit of work to code that.

It would be a lot better if there was a user friendly conf editor and I have made that suggestion before but would not be possible on the old GUI as the current devs don't really have the skills for that. Since moving to web settings it would be a lot easier for them to do in the future, but would be a low priority though.

In the meantime everything you need to know is in the Defaultrenderer.conf where it documents all the settings and lists all the formats and their codes.

Best way to see why UMS is transcoding is to search the logs for "Final Verdict" which will show if a video is to be streamed or transcoded, then scroll up to see the decision making process. It will usually say something like "failed to match" x on each line of the supported format in the conf, you can use this to tweak the conf.
Logs are important for us to help, Please follow This Link before asking for support. Just a forum cleaner, Will help if I can but no expert.
johnrom
Posts: 3
Joined: Sun May 07, 2023 12:42 am

Re: Emulating LG Smart Share behavior

Post by johnrom »

mik_s wrote: Sun May 07, 2023 4:33 pmIt is far better to get the conf right to play your videos than to create a whitelist.
You might have hundreds of videos in a format that can be streamed but is not defined in the conf and it wold not be practical to go though them all to add to the list.
Hehe, sorry, by "whitelist" i did mean the # Supported video formats section of the conf file. It's already like a sort of database, indexed by containers. Upon receiving the okay signal UMS would just add the properties of the file to it.
mik_s wrote: Sun May 07, 2023 4:33 pmAlso the confs can not be changed by UMS (would need admin privileges) and they would be overridden when UMS is updated.
Those seem like they should be easily solvable problems. Create a custom conf out of the default one for the renderer first and put it somewhere UMS has writing privileges. I'm assuming it does write something, somewhere, to keep the settings.
mik_s wrote: Sun May 07, 2023 4:33 pmBest way to see why UMS is transcoding is to search the logs for "Final Verdict" which will show if a video is to be streamed or transcoded, then scroll up to see the decision making process. It will usually say something like "failed to match" x on each line of the supported format in the conf, you can use this to tweak the conf.
That's useful, thanks!

BTW, I did try to add disable_transcoding = true to that conf you linked to. And I commented out all the "Supported" lines, while leaving the subtitle related ones as is. No dice. It wouldn't stream the subtitles. But that would be something I was looking for in the first post: don't bother with transcoding or languages, just stream the video and the subtitle file if available.
Post Reply