RetroPie forum home
    • Recent
    • Tags
    • Popular
    • Home
    • Docs
    • Register
    • Login
    Please do not post a support request without first reading and following the advice in https://retropie.org.uk/forum/topic/3/read-this-first

    Bug (solved): OMXPlayer on Stretch-based builds stutters on composite

    Scheduled Pinned Locked Moved Help and Support
    stuttervideosomxplayeremulationstatioscreensaver
    56 Posts 7 Posters 15.1k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • mituM
      mitu Global Moderator @matchaman
      last edited by

      @matchaman If you have a Github account, you should report the issue on the omxplayer's project page (https://github.com/popcornmix/omxplayer/issues), while searching for similar issues to this topic, I haven't encountered similar reports - most likely due to the fact that the switch to 4.14 kernel in Raspbian happened recently.

      matchamanM 1 Reply Last reply Reply Quote 0
      • matchamanM
        matchaman @mitu
        last edited by

        @mitu I just did that :) I hope it's solved because more and more people using 240p via composite will encounter this soon.

        Who would ever believe that a simple audio device switch would cause a system-wide slowdown and only on analogue A/V...

        1 Reply Last reply Reply Quote 1
        • matchamanM
          matchaman
          last edited by

          Update: Oh dear... ALSA:HW:0,0 fixed it BUT causes some slight input lag within the menus. I initially thought it's my imagination or due to the large amount of videos and art. Then I played around and used localinstead of ALSA:HW:0,0and the (slight) delay was gone!

          However, that made videos stay silent in HDMI so it's not a real fix. Later today I'll make a new fully updated Jessie build again and check performance between both, local and ALSA:HW:0,0.

          The saga continues...

          pjftP 1 Reply Last reply Reply Quote 0
          • pjftP
            pjft @matchaman
            last edited by

            @matchaman ...but did local solve your specific problem though? You're running things via composite, so why is local not a solution to your specific issue? Was it more about whether to change the default option?

            1 Reply Last reply Reply Quote 0
            • matchamanM
              matchaman
              last edited by matchaman

              I'm using a CRT TV in my office room above my PC monitor and when I game in the living room I connect it via HDMI, so I keep swapping composite and HDMI.

              For now I'll probably keep switching between local and HDMI but both had been very convenient until Stretch and the afore issues.

              The main problem is that I mostly use ES Kiosk mode because friends and relatives sometimes mess up my collections. Right now I'm between ALSA (and those slight hiccups) and manual switching each time.

              pjftP 1 Reply Last reply Reply Quote 0
              • pjftP
                pjft @matchaman
                last edited by

                @matchaman Got it.

                Definitely keen on seeing how it goes over at the omxplayer issue tracker.

                1 Reply Last reply Reply Quote 0
                • ohmycommodoreO
                  ohmycommodore @matchaman
                  last edited by

                  @matchaman Just encountered this issue and posted here (https://retropie.org.uk/forum/topic/20350/slow-scratchy-video-previews-on-crt-but-not-hdmi/4). Will be looking into this tonight. After reading, I'm not sure if you did get things working on both composite and HDMI. That's what I'm after as well, and thus I noticed the composite-only stuttering / slowdown issue.

                  ohmycommodoreO 1 Reply Last reply Reply Quote 0
                  • ohmycommodoreO
                    ohmycommodore @ohmycommodore
                    last edited by

                    @matchaman So is audio_pwm_mode=0 the complete solution? Or is there another step related to tweaking OMX player?

                    1 Reply Last reply Reply Quote 0
                    • S
                      SinisterSpatula
                      last edited by SinisterSpatula

                      My apologies for bringing this topic from the dead, but I'm definitely still having this problem and it's not really solved, just workaround solutions, and this is the most relevant place to ask about it. Also, I'm not using composite video and still see the issue. I'm seeing it on pi zero which has the same audio chip. The workarounds mentioned here do work for fixing it for me, when using emulationstation. I thought it must be a bug in ES, or in OMX player, but today I saw something that makes me think it's actually a raspbian issue. I was trying out Pegasus front end, and tried enabling hardware video acceleration by installing gstreamer1.0-omx and the exact same slow/stuttering/problematic video occurs. If I uninstall gstreamer1.0-omx and use software rendering for the same video, the issue goes away. I'm on a Pi zero. I have no idea how to switch the audio output away from "both hdmi and analog" when using gstreamer. It's been a problem on 4.4 and still on the latest 4.5.1 (which is what I'm using, stock 4.5.1 happens both with ES/omxplayer and Pegasus/gstreamer). I'm really puzzled why I can't find anyone else asking about this, probably because the workaround works for 99.99% of people who are using OMX player and ES. Any idea's how to achieve the same workaround for gstreamer1.0-omx ? (switching audio output device to Alsa HW 0,0 and having gstreamer avoid sending audio to both hdmi and analog?)

                      pjftP 1 Reply Last reply Reply Quote 0
                      • pjftP
                        pjft @SinisterSpatula
                        last edited by

                        @SinisterSpatula interesting. I should have recalled this thread when I was running things on composite a few weeks ago but alas I didn't!

                        It is indeed a Raspbian/OMX... quirk, let's call it?

                        What worked for me was adding in

                        audio_pwm_mode=0

                        to config.txt , which was also the suggestion here:

                        https://retropie.org.uk/forum/topic/17864/raspberry-pi-ridiculously-slow-when-splashscreen-service-is-enabled/

                        See if it makes a difference.

                        S 1 Reply Last reply Reply Quote 0
                        • S
                          SinisterSpatula @pjft
                          last edited by

                          @pjft thanks for the reply! Well, I just tried pwm_audio_mode=0, 1, and 2. For 0 and 2 they were both equally bad. I tried 1 also just to see, and it was slightly better than 0 and 2 but still slow/not real-time. I'm also seeing this error on the console ALSA lib pcm.c:8306:(snd_pcm_recover) underrun occurred repeatedly, during the test play.

                          1 Reply Last reply Reply Quote 0
                          • pjftP
                            pjft
                            last edited by

                            Sorry, I don't have a lot more ideas here, apologies. Does running standalone omx player result in the same stuttering?

                            S matchamanM 2 Replies Last reply Reply Quote 0
                            • S
                              SinisterSpatula @pjft
                              last edited by SinisterSpatula

                              @pjft No worries, with OMX I just don't do -o both and it works fine yes. If I use -o both then I have the same bug.

                              1 Reply Last reply Reply Quote 0
                              • matchamanM
                                matchaman @pjft
                                last edited by

                                @pjft said in Bug (solved): OMXPlayer on Stretch-based builds stutters on composite:

                                Does running standalone omx player result in the same stuttering?

                                Absolutely! And yes, this issue remains unsolved.

                                1 Reply Last reply Reply Quote 0
                                • First post
                                  Last post

                                Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.

                                Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.