Permalink
Browse files

Fixed bug that caused embedded subtitles to be displayed instead of e…

…xternal
  • Loading branch information...
1 parent bffab74 commit d0c36c169385f46627f56667ef8e358cf54e3540 @Happy-Neko Happy-Neko committed Apr 25, 2013
Showing with 11 additions and 2 deletions.
  1. +2 −0 CHANGELOG.txt
  2. +9 −2 src/main/java/net/pms/encoders/MEncoderVideo.java
View
@@ -4,6 +4,8 @@ Changelog:
1.82.0 - 2013-??-??
Engines:
+ MEncoder:
+ - Fixed bug that caused embedded subtitles to be displayed instead of external
tsMuxeR:
- Fixed 24-bit FLAC support with tsMuxeR
@@ -1502,19 +1502,26 @@ public ProcessWrapper launchTranscode(
* subs" options if any of the internal conditions for disabling subtitles are met.
*/
if (isDisableSubtitles(params)) {
+ // Ensure that internal subtitles are not automatically loaded
// MKV: in some circumstances, MEncoder automatically selects an internal sub unless we explicitly disable (internal) subtitles
// http://www.ps3mediaserver.org/forum/viewtopic.php?f=14&t=15891
cmdList.add("-nosub");
- // make sure external subs are not automatically loaded
+ // Ensure that external subtitles are not automatically loaded
cmdList.add("-noautosub");
} else {
// note: isEmbedded() and isExternal() are mutually exclusive
if (params.sid.isEmbedded()) { // internal (embedded) subs
+ // Ensure that external subtitles are not automatically loaded
+ cmdList.add("-noautosub");
+ // Specify which internal subtitle we want
cmdList.add("-sid");
cmdList.add("" + params.sid.getId());
- } else { // external subtitles
+ } else if (externalSubtitlesFileName != null) { // external subtitles
assert params.sid.isExternal(); // confirm the mutual exclusion
+ // Ensure that internal subtitles are not automatically loaded
+ cmdList.add("-nosub");
+
if (params.sid.getType() == SubtitleType.VOBSUB) {
cmdList.add("-vobsub");
cmdList.add(externalSubtitlesFileName.substring(0, externalSubtitlesFileName.length() - 4));

0 comments on commit d0c36c1

Please sign in to comment.