this post was submitted on 10 Mar 2024
386 points (97.8% liked)

Memes

45554 readers
691 users here now

Rules:

  1. Be civil and nice.
  2. Try not to excessively repost, as a rule of thumb, wait at least 2 months to do it if you have to.

founded 5 years ago
MODERATORS
 

Now I don't have to : right-click > english audio and right-click > french subtitle. It launches every video of the season ready to go. It was worth it, right?
Now it's time to enjoy my day. Oh wait! (it's 6 am here)

you are viewing a single comment's thread
view the rest of the comments
[โ€“] [email protected] 39 points 8 months ago* (last edited 8 months ago) (3 children)

You could have saved hours by just using mkvpropedit writing a simple 3 line bash script that loops through your files.

Just saying ๐Ÿคท๐Ÿผ

[โ€“] Zachariah 21 points 8 months ago (1 children)

Maybe it took ten hours to find this solution?

[โ€“] pete_the_cat 14 points 8 months ago (1 children)

9 hours and 59 minutes to find the solution, 60 seconds to write the code.

[โ€“] [email protected] 5 points 8 months ago* (last edited 8 months ago)

Maybe try c+v and do it in 10 seconds?

9h 59m and 10s

You're welcome !

[โ€“] [email protected] 2 points 8 months ago (1 children)

That's what I already did. And finding the good mkvpropedit command was long.
But here I wanted to automate that and just having to choose the audio and subtitles languages and it executes the mkvpropedit command.

[โ€“] [email protected] 2 points 8 months ago (1 children)

Thanks for sharing your script :) I never thought you would need such a complex (not a programmer so it's complex for me xD) script. This seems a full automation and looks great ! Well done, it was worth it !

[โ€“] [email protected] 2 points 8 months ago

Thank you very much. It's nice to hear it. I have to say that it's very satisfaying to have a "complete" script with clean code and comments.

[โ€“] Blue_Morpho 1 points 8 months ago (2 children)

I'm not sure if it's fixed now but a few years ago Plex ignored the properties and played the first audio stream it found. I had Scooby Doo with Portuguese as the first audio track and although mkvpropedit worked when playing back in VLC, in Plex it would still play Portuguese as default. I had to re merge the streams with English as the first track for Plex to play English by default.

[โ€“] [email protected] 2 points 8 months ago

Plex has a built in solution for that now

[โ€“] [email protected] 2 points 8 months ago* (last edited 8 months ago) (1 children)

I'm thinking of ~~2~~ 3 issues here.

Either your file had the propertie flag --forced-display-flag for the audio track 1 and this would force the audio 1 to play even if you changed the flag-default with mkvpropedit. In that case you have no other choice to remux your file with mkvmerge and change the flag to --forced-display-flag 1:no (if it's the audio track 1) I have no idea why someome would force an audio track....

Or you didn't used the --edit track:s1 flag with the flag-default propertie, which uses mkvmerge under the hood. Reading through my notes there is a superuser.com link talking specifically about that, and how it could fuck up your tracks order if you don't use the track flag.

Edit: This is only true if your player is capable to select the audio based on the flag default or forced. Otherwise you have to remux the file and change the order of tracks with the --track-order flag with mkvmerge. ~~This could be the case for Plex, you can probably find that info in the plex documentation !~~

Edit2: Plex seems to use both but I would suspect plex or bad flags being the culprit here rather than mkvtools.

[โ€“] Blue_Morpho 2 points 8 months ago

Yes, the problem was Plex. Other players were fine.