smplayer-dev / smplayer

Free Media Player for Windows, Linux and Mac OS with YouTube support.
https://smplayer.info
GNU General Public License v2.0
673 stars 95 forks source link

Needs double press button to unpause #986

Open kmikita opened 5 months ago

kmikita commented 5 months ago

Needs double press button to unpause. Maybe depends on #904.

Steps to reproduce the behavior:

  1. set pause (button on panel or hot key)
  2. set unpause (no action)
  3. set unpause again (playback resumed)

    • SMPlayer version: 24.5.0 rev. 10277
    • OS: Lubuntu 18.04, Xorg 21.1.13, Openbox
    • MPV version: 0.38.0, ffmpeg 7.0.1
SMPlayer log ``` [20:03:37:687] Core::play_or_pause [20:03:37:688] Core::pause: current state: "Playing" [20:03:37:689] MPVProcess::sendCommand: "set pause yes" [20:03:40:095] Core::play_or_pause [20:03:40:098] Core::pause: current state: "Playing" [20:03:40:100] MPVProcess::sendCommand: "set pause yes" [20:03:40:119] MPVProcess::parseLine: paused [20:03:40:122] Core::changePause [20:03:40:126] Core::changePause: mplayer reports that it's paused [20:03:40:127] BaseGui::displayState: "Paused" [20:03:40:128] MiniGui::togglePlayAction [20:03:40:129] BaseGui::togglePlayAction [20:03:40:134] BaseGui::checkStayOnTop ```
0x7633 commented 1 month ago

I have this bug too.

SMPlayer v. 24.5.0 (revision 10277)

$ mpv --version
mpv 0.37.0 Copyright © 2000-2023 mpv/MPlayer/mplayer2 projects
libplacebo version: v6.338.2
FFmpeg version: 6.1.2
FFmpeg library versions:
   libavutil       58.29.100
   libavcodec      60.31.102
   libavformat     60.16.100
   libswscale      7.5.100
   libavfilter     9.12.100
   libswresample   4.12.100

video: https://github.com/user-attachments/assets/f2303781-4fd6-46a4-a292-a8b5031638a5

sinekonata commented 1 month ago

I can also reproduce the bug in manjaro with default smplayer settings on version

24.5.0 (revision 10277) Using Qt 5.15.14 (compiled with Qt 5.15.13) Using MPV v0.38.0-dirty

All of this is with mpv, mplayer never has that issue, nor does vanilla mpv. It happens either

  1. randomly by pressing pause or _play_or_pause_ every 3-12 times, maybe depending on timing/rhythm, but not sure.
  2. 100% when using _framestep, but 0% when using _frame_step_back_ for some reason.

What seems to happen is that on these random few pauses, as with _framestep, the video actually pauses, and the OSD reflects that, but the player interface text will show "Playing" instead of "Pause". As for the the button's icon, it will either

  1. on the random pause : change from the "pause bars" to the "play triangle" as if indeed paused.
  2. on _framestep : stay consistent with the "Playing" text and show the bars as if still playing.

But since in both cases the video is actually paused while part of the interface code thinks it's playing, when pressing play, nothing happens, no matter how often it's pressed. But if instead we press _play_orpause or pause, then :

  1. on the random pause : the button icon will flicker from triangle > bars > triangle very fast, often too fast to see.
  2. on _frame_step_ : the icon switches from bars > triangle.

At which point all is reset and the video/osd, button and text interface all agree that the video is paused. Now pressing pause, _play_orpause, or play will all resume the video.

I could keep testing things but it's late :D I hope this is enough info, if you have more questions feel free to ask. I'll use mplayer in the mean time, and thank you for all your precious work.

AngryPhantom commented 1 month ago

I can confirm this too with any recent mpv version: 0.37, 0.38 and 0.39.

smplayer-dev commented 1 month ago

I can't reproduce this problem in my computer with mpv 0.38.