• Recent
  • Tags
  • Popular
  • Home
  • Docs
  • Register
  • Login
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

Moonlight Screen Rotation

Scheduled Pinned Locked Moved Help and Support
moonlightscreen rotation
16 Posts 2 Posters 2.9k 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.
  • A
    Applepie2
    last edited by 26 Dec 2022, 19:07

    I have just setup Moonlight and the streaming works perfectly. However, my setup is using a DPI screen which is portrait by default, so I have already had to configure emulationstation, retroarch etc to rotate the screen 90 (or 270) degrees.

    For most non-libretro core emulators I find that there is not normally a screen rotation built in. However I found on the Moonlight embedded github that there is actually an option in the configuration for this.

    However, when I add rotate = 90 into the global Moonlight config at ~/config/all/moonlight/global.conf, I don't get any change to the screen orientation. I've tried other options in the config and it appears they all work, but I can' work out why rotate isn't.

    I had a brief skim over the moonlight.sh file and it doesn't appear that the rotation variable from the config is actually being passed to Moonlight (as far as I can tell). Am I correct in this assumption, and if so, is this because the version of Moonlight on Retropie doesn't support this feature, or has it just not be included?

    Any advice on how to successfully achieve screen rotation for Moonlight would be much appriciated.

    1 Reply Last reply Reply Quote 0
    • M
      mitu Global Moderator
      last edited by 27 Dec 2022, 07:54

      Please fill out the info requested in https://retropie.org.uk/forum/topic/3/read-this-first.

      A 1 Reply Last reply 27 Dec 2022, 12:16 Reply Quote 0
      • A
        Applepie2 @mitu
        last edited by 27 Dec 2022, 12:16

        @mitu Sorry about that, it totally slipped my mind!

        Pi Model or other hardware: Raspberry Pi 4B
        Power Supply used: Official 3A RPI Power Supply
        RetroPie Version Used: 4.8.2
        Built From: Raspberry Pi Imager - No background OS
        USB Devices connected: Custom Teensyduino Controller
        Controller used: Custom Teensyduino Controller
        Emulator: Moonlight
        How to replicate the problem: Use the rotation = x parameter in the Moonlight global.conf

        1 Reply Last reply Reply Quote 0
        • M
          mitu Global Moderator
          last edited by 27 Dec 2022, 16:13

          As far as I can tell, the rotation parameter is supported when using the omx video decoder (when platform=pi) and it should work with the default RetroPie 4.8.2 image.
          Can you add verbose to the .conf file and then - after running moonlight - post the log file (/dev/shm/runcommand.log) to pastebin.com ?

          A 1 Reply Last reply 27 Dec 2022, 16:37 Reply Quote 0
          • A
            Applepie2 @mitu
            last edited by 27 Dec 2022, 16:37

            @mitu Here is the pastebin of the log:

            https://pastebin.com/9FTYzvXT

            1 Reply Last reply Reply Quote 0
            • M
              mitu Global Moderator
              last edited by 27 Dec 2022, 17:51

              Hm, that doesn't look like a verbose log. Perhaps running manually the command line (shown at the top of the log file) with -verbose or -debug would display more diagnostic info ? I think you can run it manually from a SSH session (just exit EmulationStation before starting moonlight).

              A 1 Reply Last reply 27 Dec 2022, 18:37 Reply Quote 0
              • A
                Applepie2 @mitu
                last edited by Applepie2 27 Dec 2022, 18:37

                @mitu I've managed to launch Moonlight directly from the .sh file, although I did have to edit the -config parameter slightly from how it appeared in the runcommand.log. Instead of passing in "/home/pi$, I had to include the full path to the config for it to successfully launch ("/home/pi/.config/moonlight/global.conf").

                The -verbose flag worked successfully, please find the full verbose log here:

                https://pastebin.com/QJLN2SjV

                M 1 Reply Last reply 27 Dec 2022, 18:44 Reply Quote 0
                • M
                  mitu Global Moderator @Applepie2
                  last edited by 27 Dec 2022, 18:44

                  @Applepie2 said in Moonlight Screen Rotation:

                  The -verbose flag worked successfully, please find the full verbose log here:
                  https://pastebin.com/QJLN2SjV

                  Cannot see the log: Error, this is a private paste or is pending moderation. If this paste belongs to you, please login to Pastebin to view it.

                  A 1 Reply Last reply 27 Dec 2022, 18:51 Reply Quote 0
                  • A
                    Applepie2 @mitu
                    last edited by 27 Dec 2022, 18:51

                    @mitu If I posted it as a guest post it kept getting auto-removed, so I tried to post it through my account instead and it appears that has triggered moderation.

                    I'm guessing it is some of the game names in the xml tags that might be causing issues. I've removed the xml tags relating to my desktop PC system, steam and game names. Where these have been removed I've just replaced them with <REDACTED>.

                    Hopefully this version is accessible:
                    https://pastebin.com/WB02eXLM

                    M 1 Reply Last reply 27 Dec 2022, 19:10 Reply Quote 0
                    • M
                      mitu Global Moderator @Applepie2
                      last edited by 27 Dec 2022, 19:10

                      @Applepie2 Yes, it's accessible now, though unfortunately I don't see anything related to rotation there, just the messages regarding the viewport (wxh@fps). It does detect the correct platform (Pi).

                      Can you try adding -rotation 90 parameter to the command line and see if it works this way ?

                      A 1 Reply Last reply 27 Dec 2022, 19:14 Reply Quote 0
                      • A
                        Applepie2 @mitu
                        last edited by 27 Dec 2022, 19:14

                        @mitu I try to use either a parameter -rotation 90 or --rotation 90 to the command line, then it tries to connect to an ip address of 90. Sadly, I don't think rotation is supported that way.

                        M 1 Reply Last reply 27 Dec 2022, 19:17 Reply Quote 0
                        • M
                          mitu Global Moderator @Applepie2
                          last edited by 27 Dec 2022, 19:17

                          @Applepie2 Try with -rotate 90.

                          A 1 Reply Last reply 27 Dec 2022, 19:27 Reply Quote 0
                          • A
                            Applepie2 @mitu
                            last edited by Applepie2 27 Dec 2022, 19:27

                            @mitu You've got it! That did the trick!

                            Do you know which file calls this, so I can permenantly add the -rotate 90 parameter?

                            EDIT: Turns out the parameter for the config is (of course) also just called rotate rather than rotation. Just double checked their GitHub again and their example config definitely has the wrong parameter.

                            Thanks again for all your help!

                            M 1 Reply Last reply 27 Dec 2022, 19:45 Reply Quote 1
                            • M
                              mitu Global Moderator @Applepie2
                              last edited by 27 Dec 2022, 19:45

                              @Applepie2 said in Moonlight Screen Rotation:

                              Just double checked their GitHub again and their example config definitely has the wrong parameter.

                              Good find ! It will need to be corrected.

                              A 1 Reply Last reply 27 Dec 2022, 23:59 Reply Quote 0
                              • A
                                Applepie2 @mitu
                                last edited by Applepie2 27 Dec 2022, 23:59

                                @mitu I've raised this as an issue on their repository, hopefully they will correct their example before too long. Thank you again for your assistance in this matter.

                                M 1 Reply Last reply 28 Dec 2022, 04:28 Reply Quote 0
                                • M
                                  mitu Global Moderator @Applepie2
                                  last edited by 28 Dec 2022, 04:28

                                  I meant to send a PR myself, but looks like the Github's web interface didn't go through with it. I've amended their Wiki page with the command line options and sent a small PR to fix the sample .conf from the repository.

                                  1 Reply Last reply Reply Quote 0
                                  16 out of 16
                                  • First post
                                    16/16
                                    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.

                                    This community forum collects and processes your personal information.
                                    consent.not_received