Adding RetroFE: emulator launches behind the front-end
-
@phulshof I don't know enough about RetroFE, but EmulationStation does de-init the SDL renderer before launching an emulator, and then re-inits it when coming back.
If the emulator launches, though, it might be a layer thing - I believe SDL on the Pi is hardcoded to layer 10000 so it might be that the emulator is being rendered behind it. Either coming up with your own custom SDL library with a different layer value, in hope that it works, or the best would be to effectively shut down SDL and re-initing it again afterwards.
-
@pjft said in Adding RetroFE: emulator launches behind the front-end:
@phulshof I don't know enough about RetroFE, but EmulationStation does de-init the SDL renderer before launching an emulator, and then re-inits it when coming back.
If the emulator launches, though, it might be a layer thing - I believe SDL on the Pi is hardcoded to layer 10000 so it might be that the emulator is being rendered behind it. Either coming up with your own custom SDL library with a different layer value, in hope that it works, or the best would be to effectively shut down SDL and re-initing it again afterwards.
Thanks for the reply. :) I had a look at the ES code, and did notice that it de-inits the renderer; how does one prevent the (tty?) background from showing up briefly though? I could add that to RetroFE, though it would take some effort since textures are kept with all objects, and some of those are on the stack. It could be done though; I was just hoping there was an easier solution. :) I played around with SDL_HINT_RPI_VIDEO_LAYER as well, but had no luck with it so far.
-
@phulshof Hm.
I'd take a look at the runcommand code. I'm not sure exactly what you mean by the tty background showing up. I expect there will be a transition period where the black background will show, as it waits for loading.
Do you mean the runcommand dialog? That can be configured in RetroPie-Setup. Try hiding the dialog there and see if that's what you're looking for.
Or do you see something else when using RetroFE?
-
@pjft said in Adding RetroFE: emulator launches behind the front-end:
I'd take a look at the runcommand code. I'm not sure exactly what you mean by the tty background showing up. I expect there will be a transition period where the black background will show, as it waits for loading.
Do you mean the runcommand dialog? That can be configured in RetroPie-Setup. Try hiding the dialog there and see if that's what you're looking for.
Or do you see something else when using RetroFE?
Since I'm currently testing, I'm launching RetroFE from the tty. It might be that if I were to set up RetroFE as the default launch in stead of ES (I need to figure out how to do that too I guess) that the background will be simply black. I'll have a closer look at that. I'll also try launching ES from the tty to see if I have the same issue there; if not then that code deserves a second look for sure. :) I should probably have a closer look at the ES code anyway, because it contains some features that would suit RetroFE as well.
My apologies for all the questions; I just got my first pi a few weeks ago, so I'm still learning my way around it. :)
-
@phulshof No, not at all.
Obviously it'd be quite early for me to even suggest one such thing, but if you would want to bring over any particular set of features you find really useful from RetroFE to ES, I'm sure everyone would be happy to welcome them!
I see a black screen when launching from tty as well (other than the runcommand dialog, though), so maybe ES is actually force flushing the tty console it uses when it launches. I am not quite that familiar with that part of the code, though, but shouldn't be that tricky to figure out (hopefully).
By the way, this is what I'm referring to (though it's actually black rather than blue):
https://www.reddit.com/r/RetroPie/comments/45ouzi/how_do_i_get_rid_of_the_ugly_blue_loading_screen/
No need to apologize for any sort of questions - that's what this is all about. :)
-
I will, though the architecture of RetroFE is quite different from ES from what I've seen so far, so I'm not sure how easy it would be to port features. RetroFE was originally developed by Emb (from Don's HyperTools), and was taken over by me last year. It might be worth getting in touch with the ES developers though to see if it would be worth working together on some things. I get some occasional programming assistance, but generally it's just me doing the work in my spare time, so I know how much work is involved in it. :) ES is certainly more user-friendly in some areas than RetroFE at the moment; I need to add a configuration menu to it still (it uses configuration text files atm). It can use quite a lot of the HyperSpin artwork though, so setting up collections can be quite easy there as well.
My intention is to supply an install script for retropie that uses at least the default rom paths (so that part continues to work), and supply all the default launchers needed to use it properly on retropie. That way users will have an easy install path to use RetroFE if they want to use it. First step is to fix this launching issue though. :)
Eventually I would love to have this theme working on the pi, but I'll have to wait and see if the pi is powerful enough for it:
-
@phulshof Sounds like a plan.
I don't see, in concept, why the Pi wouldn't be able to "handle" that, though it all depends on the underlying architecture.
But one thing at a time :)
-
Since all other attempts have failed, I guess I'll get to cracking code then. :) Time to clean up SDL before launching a game... I'll make it an option so users can choose whether they need it or not.
-
@phulshof Sounds good.
Can you manage your way around the ES code?
What you're looking for may start on the Window class (init and deinit functions). I imagine it'll then go to the Renderer code as well, but that's probably the best place to start. :)
-
@pjft said in Adding RetroFE: emulator launches behind the front-end:
@phulshof Sounds good.
Can you manage your way around the ES code?
What you're looking for may start on the Window class (init and deinit functions). I imagine it'll then go to the Renderer code as well, but that's probably the best place to start. :)
Yes, thanks, that's no problem. :) I'm used to searching through large amounts of code, and ES is well structured, so it wasn't too hard. My main problem is the enormous amount of textures RetroFE leaves on the stack, so I have to unload it all, and then reload it when the game returns. I'm not yet sure what impact that will have on performance.
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.