Hmm⊠Not sure why you are not seeing the edit button on your other profiles. I just checked on my managed user and another full Plex account I have and it appeared on both.
For âTV Show configurationâ I just checked and those settings cannot be changed at the library level, so it seems like you might have gone through and actually set it for each series already. I do not believe there is a way to reset the language defaults for a library.
âHow to set forced?â section.
First, this is the feature suggestion I voted on, Give Option to Play Default or First Audio Track. Itâs been a while since Iâve looked at it, but it should be relevant. Note it only has 23 votes and also that vote count does not necessarily mean a lot because there are feature requests out that for years (older than the one I linked) with hundreds of votes and no movement.
Yes, you can bulk set the different flags on a track. You would actually use mkvpropedit from MKVToolNix. An example of using mkvpropsedit to update the files (I have this saved as a .bat file and this particular example would set the first subtitle as forced and the next as just a âregularâ subtitle (i.e., SDH subtitle without the SDH stuff). I also included the option to set the SDH/HI flag, but since it is set to 0 that means it will be off.
for %%f in (*.mkv) do (
echo %%~nf
"C:\Program Files\MKVToolNix\mkvpropedit" "%%~nf.mkv" --edit track:s1 --set language=en-US --set flag-forced=1 --set flag-hearing-impaired=1 --set flag-default=0 --set "name=Forced" --edit track:s2 --set language=en-US --set flag-forced=0 --set flag-hearing-impaired=1 --set flag-default=0 --set "name=English"
)
For your 2 different scenarios, I have a suggestion though it depends on how you plan on coding it. To quickly get the information you are looking for, I would suggest grabbing a copy of your Plex DB and then using something like DB Browser for SQLite to open that database to query it. Easiest way to do that is go to the settings from the web app, scroll down to the âManageâ section in the left panel and then click on âTroubelshootingâ. From the âTroubleshootingâ page, click the âDownload Databaseâ button and wait for it make a copy of your DB and then save the zip file and extract the DB. Use DB Browser to open it (hint rename the extension to end with .db and yo ucan associate that to DB Browser) and then you can go to the âExecute SQLâ tab and run this query:
SELECT mp.file, COUNT(mp.file) "total subs"
FROM media_parts mp INNER JOIN media_streams ms
ON mp.id = ms.media_part_id INNER JOIN media_items mi
ON ms.media_item_id = mi.id
WHERE ms.stream_type_id LIKE 3
AND mi.library_section_id = (SELECT id FROM library_sections WHERE name = 'Anime')
GROUP BY mp.file
HAVING COUNT(mp.file) > 1
Change the name (where I have it set to âAnimeâ to the name of your Anime library if it is different. What the above query will do is simply give you a list of the file path (as shown in Plex) and total subs. You can change the line HAVING COUNT(mp.file) > 1 to be = 2 or > 2 if you want to separately get the files that have 2 subs and 3 or more subs.
You can then either save the results to a CSV file (toolbar above the SQL tab 4th to last icon) or you can click the top left corner of the results grid and then right click and select one of the âCopyâ options and then paste it into an Excel/Google Sheets file.
Going back to my âdepends on how you plan to code itâ sentence, you could then use that CSV file as an input to loop through and then create the mkvprops command you would need.
I process my files in a certain way so I have a Python script I wrote that will analyze the file and determine the track info and then do what I used to do manually automatically. To get that info I actually use 3 different programs, ffprobe (part of ffmpeg), mediainfo (download the CLI version) and mkvmerge (part of MKVToolNix). I actually use the mkvmerge data as the main and the others are used a supplements, but that will get you the info you need which could then allow you to determine number of subtitle tracks via code and go on from there.
I label the SDH tracks as such because if I have an SDH subtitle and a âregularâ subtitle, I personally prefer the âregularâ subtitle most of the time as I do not need all the additional info. I am honestly probably the only one on my server that actually pays attention to that, but since my server is first and foremost for me and I decide what gets done, I process my media to how I want it. The people I share with are generally just happy to have the access.
Regarding you question about special text vs metadata, Plex will look at the forced track flag and hearing impaired flag from a MKV and display âforcedâ or âsdhâ for the subtitle based on that. See this example of 2 PGS subtitles in a movie with one having the hearing impaired flagged checked and Plex includes SDH next to the language.
The text underneath is set by me as the âname=â in my bat example above. That leads me to text, which is Plex does not use that to determine anything, but if you include a name for the track, Plex will parse that out and display it in the drop down (on most clients I believe, I think only a few do not show it).
Hopefully that at least starts to answer you questions. I am more than willing to help as much as I can, I just want you to be aware I am not a programmer but I like programming (but I would consider my self probably average if that). The other thing is that a lot of this comes down to personal preferences, so whether you should mark SDH subtitles as such ultimately comes down to you and if you feel it would actually be worth it. Similar to how you choose to convert SRT to ASS, whereas I had always preferred SRT for the most part (that has slightly changed with the better implementation of ASS subtitles in clients).
Let me know if you have any more questions/need anything clarified and I will answer as best as I can.
-Shark2k