Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stop showing automatically found external subtitles by default #699

Closed
wants to merge 9 commits into from

Conversation

mjfwalsh
Copy link

@mjfwalsh mjfwalsh commented May 2, 2019

Subtitles are currently enabled by default if available. This patch hides them. They can still be toggled on and off as now, it just starts playing the file with the subtitles hidden.

@popcornmix
Copy link
Owner

Does changing:

m_subtitle_index = 0;

to = -1
achieve the same effect with -t 0 on command line?

@mjfwalsh
Copy link
Author

mjfwalsh commented May 3, 2019

After a bit of testing I can't replicate issue #603. When I play a file with embedded subtitles they're off by default, unless enabled with -t 0.

What is an issue, is automatically found external subtitles. These are on by default with no way of turning them off from the command line.

The modified pull request will turn external subtitles off by default, unless they're specified via the --subtitles command line option.

@mjfwalsh
Copy link
Author

mjfwalsh commented May 6, 2019

@popcornmix in answer to you question, changing m_subtitle_index doesn't make any difference. The problem is line 1141:

if(m_subtitle_index == -1 && !m_has_external_subtitles)
    m_player_subtitles.SetVisible(false);

It make subtitles visible when m_has_external_subtitles is set to true so it doesn't matter when value is assigned to m_subtitle_index.

My (new) solution is to set m_subtitle_index to 0 when the the user passes --subtitles on the command line and ignore m_has_external_subtitles when hiding or not hiding the subtitles.

This retains the current position when a specific file is passed using --subtitles (the subtitles are displayed), but hides, by default, external subtitles found using the path.

@mjfwalsh mjfwalsh changed the title Add command line option to hide subtitles Stop showing automatically found external subtitles by default May 9, 2019
@DanielGlaas
Copy link

Hi, I stumbled around this issue and I'm wondering why the provided patches are not yet merged. It is really a pitty that when having automatically found subtitles that omxplayer simply crashes.

@mjfwalsh mjfwalsh closed this Jun 30, 2020
@DanielGlaas
Copy link

As far as I can see your commits are not merged yet. Is this correct?
From that point of view the issue is still open until the pull request is merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants