Video Screensaver in Emulation Station
-
Hi everyone. I've got a treat for you all. As a little side-project of the video preview development, I extended the screensaver functionality in ES to include a new option for a "Random Video".
What this does is that when the screensaver timeout expires, the screen fades out then fades in a video which is picked from any game from any system at random. After 30 seconds another random video is picked. This continues until the user dismisses the screensaver.
If none of the gamelists contain any videos then the screensaver reverts to showing a black screen.
I've given this a really good shakedown and it works fine but once again I'm asking the wider audience for anyone that is willing to give this a go before submitting a PR to the RetroPie ES.
You can download it from here.
Installation instructions:
-
Either download a fresh copy of retropie from https://github.com/RetroPie/RetroPie-Setup/releases/download/4.1/retropie-4.1-rpi2_rpi3.img.gz and install it on an SD card or use a pre-configured (and backed up) configuration.
-
Connect the raspberry pi to the network
-
Boot the raspberry pi and exit ES back to the terminal
-
Download or copy the new ES that supports video screensaver from https://github.com/fieldofcows/EmulationStation/releases/download/v0.2-RPi-beta.2/emulationstation into the home directory, e.g.
wget https://github.com/fieldofcows/EmulationStation/releases/download/v0.2-RPi-beta.2/emulationstation
- Install dependencies
sudo apt-get install libvlc5 libvlccore8 vlc-nox
- Make executable and replace the original ES
chmod +x emulationstation sudo cp emulationstation /opt/retropie/supplementary/emulationstation/
In the screensaver settings in the ES GUI your should now see an option for "Random Video". Assuming you have some <video> tags in you gamelists you should see a full-screen video when the screensaver is activated.
-
-
I just remembered that the current download of retropie does not yet include the video preview so I've updated the steps above to install the dependencies required for playing video.
-
So I installed a new RetroPie image on Raspberry Pi 3. Next, I installed sselph scraper to set read gamelist from rom folders, and I put a couple of videos for the Sega Genesis system to test it out after editing the gamelist file.
And it works! A few things I noticed. I'm testing on a 1080p monitor, so when it plays 480p videos the screensaver stretches across the screen. Also, it looks like there are occasional screen tearing and small artifacts while the video is being played. I checked the videos I have on my computer and didn't notice the same effects. It's noticeable but not too drastic. Lastly, when I didn't close out a video tag properly in the gamelist file, the screensaver would default to a dim screen which is nice. I haven't tested adding videos to multiple systems yet so I will get to that a bit later.
I don't know if anyone else is interested, but would it be possible to have a silent version? The crazy request would be for a system name and game title to show up while it's playing just in case I load up a bunch of videos and have no clue what I'm watching but want to play it. But that last one is probably a bit too much haha
Otherwise I think this is pretty good. Nice work!
-
Just realized that if the theme doesn't support a system, videos for that system also won't show up. I tested a couple more for SNES and the screensaver works fine. To note, I also let the RetroPie run for at least a few hours with the screensaver on and it was about 15 degs hotter than the idle state of 50 degs C.
I think the video tearing might be an issue on my side since they also appear for video preview in individual system. I checked Nismo's videos for his theme and his video previews look fine.
I had to update apt-get in order to install the above dependencies. I also installed vlc-plugin-sdl mentioned in the video preview thread just to see if it improved the tearing but didn't notice any. I'll try again later to see if I can fix it.
-
@CourierSS Thanks for testing this and I'm glad it seems to work ok. In summary, you have seen these issues/suggestions:
- It would be nice to be able to turn off sound. i guess this could be simply achieved with two screensaver entries - "Random Video" and "Random Video (no sound)"
- Raspbery Pi gets hotter - this is to be expected. Is it a problem? I might mean that people need to ensure their builds include enough ventilation. VLC used for the video preview is not (as far as I am aware) using the hardware codec. I'm not sure if it's possible to use it but maybe if we can the CPU will run a little cooler. It's worth investigating.
- Only videos from systems supported by current theme are used. I'll look into this
- Video 'tearing'. This might be down to how the video is rendered to the screen. I'll have a look
- Show the game title as an overlay on the video
Have I missed anything?
Thanks again for testing.
-
@fieldofcows: I like!
I've been thinking about a better screensaver, but never got my head wrapped around how I should do it.I'd like it to work as an attract mode functionality, luring people at a party into playing by showcasing random games.
So, it will not really act as a proper screensaver, which returns you to where-ever you left. Rather it will actually change the selection to where the screensaver left it, so you can play that game (that got your attention in the first place) directly.To that extend I had already implemented a 'gotoRandomGame()' that just jumps to a random game in a random system. I think to combine that with your work on video-support, and now a nicely separated screensaver component, we might be very close!
-
That sounds about right. For number 2, it was just a note for those who are like me and leave their Raspberry Pi running all the time. I usually don't turn it off, or forget to, so I figure it would be useful information for others to know. I think the temperature is fine as well. I also realized that the video snaps I've seen show the game title at the end, so doing some sort of overlay with the system and game title while the screensaver is showing wouldn't be needed.
I'm going to try a reinstalling RetroPie in a bit and seeing if there are any differences with my results.
-
@CourierSS said in Video Screensaver in Emulation Station:
doing some sort of overlay with the system and game title while the screensaver is showing wouldn't be needed
Oh, I forgot about that one. I've edited my previous post and added a number 5 :) I had planned to do this at some point anyway - one of my gripes about my current bartop (not using retropie) is that the video screensaver doesn't tell you what game it is showing.
-
I made a mistake with number 3. I was loading up wonderswan/color videos but forgot that the core for it wasn't installed by default so naturally it wouldn't play. After loading up the core, it worked fine, even if the theme didn't support it.
I reinstalled RetroPie, but I still see the tearing/artifacts showing up on the videos with the video being stretched beyond its original aspect ratio to fit my 16:9 screen.
Also, I noticed a couple more things. While in one of the systems with a video preview playing, the screensaver will activate and both sounds from the video preview and screensaver will play at the same time. When playing the screensavers, it seems to repeatedly play three videos even though I have loaded up about 10-12 videos. If I stop the screensaver then let it run, it picks three videos to replay again.
-
If a video is less than 30 seconds in length, will it loop?
-
@robertybob said in Video Screensaver in Emulation Station:
If a video is less than 30 seconds in length, will it loop?
Yes
-
I think this would be amazing with these screensavers
http://benjaminmayo.co.uk/watch-all-the-apple-tv-aerial-video-screensavers#b3-1
-
@CourierSS did you work around the overlapping sound with screen saver and vid preview playing at the same time?
-
@fieldofcows I followed the instructions, however I just get a black screen when the screensaver kicks on. How do I add videos of the games / where do I get them. Also, can I use any video I want? in step 6. it says "assuming you have some <video> tags in your gamelists." can you elaborate further on this?
-
@fieldofcows I'm really digging your work on ES regarding videos!
Thanks for all your expertise in making ES my favorite front end to date... and I've used a LOT!!!
I'd like to add my request to above post.
Something I have always wanted in a screensaver for video games is the ability to go directly to the game the screen saver is showing. One of my favorite things to do is just to sit and watch the different games as they go by, but if one strikes my fancy I'd like to be able to immediately start it up... as opposed to navigating to it.
Is this possible?
Thanks again!
momaw27
-
@momaw27 an addition (or alternative) to this could be displaying the game name and system over the video so you know which video is playing?
-
I'm on Retropie 4.1.14 right now, and this post is 2 months old. Do I still need to do all the steps above? Specifically the ones about installing a new emulationstation?
-
@Dominus I'm afraid so. I've been busy fixing the WSOD and looking at video rendering temperature issues over getting this ready for a PR.
I might just try to squeeze the screensaver in along with the OMX video preview PR though seeing as both changes are currently being tested, albeit independently.
I've got a couple of things I want to include with the screensaver before it's finished though based on suggestions by others:
- Add an option to disable the sound when the screensaver is playing
- Display the system and game name on the video
I would like to consider the automatic jump to the game being shown in the video but it requires a bit more thought because I don't think we want to do that every time. Maybe when a certain button is pressed? I think that will come later though.
-
@fieldofcows Yeah I like the system and name of the game. How Attract Mode does theres. Would they be the logos, or just text? I say go with the logos! haha
-
@Dominus Ooh. Maybe. I haven't seen theirs. Can you point me to a screenshot?
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.