RetroPie forum home
    • Recent
    • Tags
    • Popular
    • Home
    • Docs
    • Register
    • Login

    How to change button icons? [DONE]

    Scheduled Pinned Locked Moved Projects and Themes
    themesretropieiconschange
    65 Posts 15 Posters 28.0k 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.
    • frgnF
      frgn @jacobfk20
      last edited by

      @jacobfk20
      Oh no, I made a mistake with the scale of the two buttons (select and start) - it can be fixed?
      I have changed the svg Images, it remains only to collect them again. help me again?
      Embarrassing happened... uncomfortable to ask you again about this :c
      SVG: https://mega.nz/#!cNYy0SLI!DZadJaEhQPamxhAa2b0fpSis9bxUQapYZW78B4Q7Q00

      Aloha from Russia, and sorry for my bad English. ¯\(ツ)/¯
      My RetroPie themes repo - https://github.com/free-gen/
      Blast16 to MDMINI mod
      DONATE HERE

      1 Reply Last reply Reply Quote 0
      • J
        jacobfk20
        last edited by

        @frgn I don't mind helping but please send me already converted files next time. I went ahead and converted this time and compiled with the change. I overwrote the old file on my drive.

        frgnF M 2 Replies Last reply Reply Quote 1
        • frgnF
          frgn @jacobfk20
          last edited by

          @jacobfk20 ok. thank you, man :)
          I have one more question - whether the possible change font gui? for him too need to generate cpp?

          Aloha from Russia, and sorry for my bad English. ¯\(ツ)/¯
          My RetroPie themes repo - https://github.com/free-gen/
          Blast16 to MDMINI mod
          DONATE HERE

          1 Reply Last reply Reply Quote 0
          • J
            jacobfk20
            last edited by

            @frgn No problem, glad to help :)
            ES font for MAIN MENU and other Gui menus are hard coded. At a quick glance I think the quick way would be to change es-core/resources/font.cpp Font::get() to pull from a different path if path is empty, or change the default path to the new font you want. I'm not too familiar with how ES handles fonts so someone else may have a better answer than me.

            frgnF 1 Reply Last reply Reply Quote 1
            • frgnF
              frgn @jacobfk20
              last edited by

              @jacobfk20
              OK, I understand you.
              if you will do it - please let me know about it.

              Aloha from Russia, and sorry for my bad English. ¯\(ツ)/¯
              My RetroPie themes repo - https://github.com/free-gen/
              Blast16 to MDMINI mod
              DONATE HERE

              1 Reply Last reply Reply Quote 0
              • J
                jacobfk20
                last edited by

                @frgn I would do this for you but if you ever update to the newest ES build it will overwrite any change done unless you cherry pick. Actually, updating even now will overwrite the changes to the button icons you have done.

                With that said-- you may like one of the next updates I'm about to release for my mod.

                frgnF 1 Reply Last reply Reply Quote 0
                • E
                  enderandrew @jacobfk20
                  last edited by enderandrew

                  @jacobfk20 That was really awesome of you to do a one-time compile and host it, but future ES updates on the RetroPie will revert this. We really need an upstream fix in the ES repository that allows for loading these files remotely, or perhaps just selecting from a menu that you want to see SNES button layout, XBox button layout, PS button layout, etc.

                  https://github.com/Aloshi/EmulationStation/issues/631

                  1 Reply Last reply Reply Quote 1
                  • J
                    jacobfk20
                    last edited by

                    @enderandrew I said this in the post above yours that's why I do not want to do the second request, especially since I'm working on a branch for my fork that does exactly that.
                    Also, thanks for creating the issue. I may do a pr after I test it in my fork for awhile.

                    1 Reply Last reply Reply Quote 1
                    • frgnF
                      frgn @jacobfk20
                      last edited by

                      @jacobfk20 I'm not going to do the update ES, since I do not see the point.
                      you could replace the font (including the last modifications)? in the archive are two types of font, as in the original ES. as well as button icons.
                      you are my hero! :)

                      Aloha from Russia, and sorry for my bad English. ¯\(ツ)/¯
                      My RetroPie themes repo - https://github.com/free-gen/
                      Blast16 to MDMINI mod
                      DONATE HERE

                      1 Reply Last reply Reply Quote 0
                      • M
                        masteryoer @jacobfk20
                        last edited by

                        @jacobfk20 how did you convert the new svg? I used the res2h tool on github and ran it on my data/resources directory and it broke the compile. It changed every binary conversion into a uint32 or whatever.

                        Am I not using the script right? I simply ran the script included in data/resources/convert.sh or whatever it's called.

                        After running it, Resources.h throws a compile error.

                        herb_fargusH 1 Reply Last reply Reply Quote 0
                        • herb_fargusH
                          herb_fargus administrators @masteryoer
                          last edited by

                          @masteryoer here's an example of what I did to make a black splash screen for emulationstation:

                          https://github.com/RetroPie/EmulationStation/pull/52/files

                          Not sure how helpful it is but perhaps you can compare the code and see what it's supposed to look like

                          If you read the documentation it will answer 99% of your questions: https://retropie.org.uk/docs/

                          Also if you want a solution to your problems read this first: https://retropie.org.uk/forum/topic/3/read-this-first

                          M 1 Reply Last reply Reply Quote 0
                          • J
                            jacobfk20
                            last edited by

                            @masteryoer It's actually been so long that I don't remember :)
                            I've also noticed that res2h has been removed from this branch for some time, it used to be included and that's what I use.

                            Maybe if you upload your resource.h file or tell me what the compilation error is I can help you further.

                            M 1 Reply Last reply Reply Quote 0
                            • M
                              masteryoer @jacobfk20
                              last edited by

                              @jacobfk20

                              It's still referenced in the emulationstation branch. It's in data/resources/generate.sh with a link to the fit repo for building it. Maybe I'll find an old source and see if I can use that one. It seems to be breaking whenever I use it.

                              I should be moving my .png or .svg over to the resources folder, then running res2h to create the header and .cpp file right? It also looks like it makes a frame.png.cpp file too. (I was changing the UIs frame element around dialogs and Windows)

                              1 Reply Last reply Reply Quote 0
                              • M
                                masteryoer @herb_fargus
                                last edited by

                                @herb_fargus

                                Yeah, I know where to change it at, but simply replacing the resources doesn't seem to work. I used frame.png which is the window border around the dialogues, changed it to a new look and replaced the original one, then recompiled and the old one was still being used.

                                1 Reply Last reply Reply Quote 0
                                • J
                                  jacobfk20
                                  last edited by

                                  @masteryoer So you're overwriting the current frame.png.cpp in data/converted with your new convered version, right?

                                  M 1 Reply Last reply Reply Quote 0
                                  • M
                                    masteryoer @jacobfk20
                                    last edited by masteryoer

                                    @jacobfk20

                                    I was attempting to. The res2h executable does it for you. I think the newer version I am using does it wrong though because it changed all the const chars to const uint16/32 and it broke resources.h

                                    Here is the output of a couple files that were modified using the new build of res2h

                                    https://gist.github.com/Ex0r/f63702473eec69ee689f9dfe18b8ba1c

                                    There is both old and new notice the differences

                                    1 Reply Last reply Reply Quote 0
                                    • J
                                      jacobfk20
                                      last edited by jacobfk20

                                      @masteryoer Ah, ok. Yes, it should be a const unsigned char. It would give error on compilation when ES attempts to bring the resource in expecting a const char*. Maybe there is a option in res2h you need to do to export as const char?

                                      I went and looked at the res2h git and it was recently updated to support 32/64 bit archives. So to do this the program will now keep it in uint8, 16, 32, or 64 depending on size.
                                      ES should expects a const char* so this is what is most likely causing you issue. A quick fix would be to get an older version of res2h that exports the const char source.

                                      M 1 Reply Last reply Reply Quote 0
                                      • M
                                        masteryoer @jacobfk20
                                        last edited by masteryoer

                                        @jacobfk20

                                        Ahh, that explains a lot. I take it, if the older version doesnt support 32 or 64 bit, I won't be able to use that version on my windows machine? Or no?

                                        Thanks for the info.

                                        Hmm. I went all the way back to the earliest release he has available, 0.3 beta, here: https://github.com/HorstBaerbel/res2h/releases

                                        using the precompiled windows binary, and it's still doing it. At this point, I am not sure what's going on, or how to fix it. Perhaps it needs to be compiled and built on the raspberry pi?

                                        1 Reply Last reply Reply Quote 0
                                        • J
                                          jacobfk20
                                          last edited by

                                          @masteryoer You can! It'll work just fine :) That 32/64 bit update just allows the archive to be stored in something bigger than an 8 bit const char array.

                                          M 1 Reply Last reply Reply Quote 0
                                          • M
                                            masteryoer @jacobfk20
                                            last edited by

                                            @jacobfk20

                                            I am an idiot, completely. It's late and i've been looking at code all day. So the problem, it appears, is that if you dont remove everything from your 'converted' folder before you run it, it tries to convert that stuff too, and it makes duplicates with the 16/32 bit stuff in it.

                                            I deleted the entire folder and re-ran res2h, and it created the correct files, using the correct const unsigned char* like it's supposed to..

                                            now to test if it works.

                                            1 Reply Last reply Reply Quote 1
                                            • 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.