I’ve written my own front end for retroarch in python, for various reasons. One of those reasons is I want to detect the highscore in certain games. It wasn’t too difficult,and runs fairly well. It is written in Python.
When my front end launches retroarch with the core and rom in the command line(using the subprocess module), it works great. When I exit emulation, emulation stops, retroarch process ends, my front end detects that and re-maximizes itself. Wonderful!
The problem is, I recently wrote some code to read the highscores for certain games(visually, through detecting pixels, not through reading memory). It works perfectly in two games, and 95% accurately in the third(work in progress).
The problem here is, that while my high score module is running, retroarch emulation stops, but the process wont end. I cant figure out why. The python script I wrote to detect high scores is definitely the problem(as it works perfectly without it), but I dont know why. It’s very small. All I do is take a screenshot using the pyscreenshot module(using scrot as a backend), open the pixel information and read in certsin pixels to determine the score. I dont actually hook in to anything.
If anyone has any ideas, I would greatly appreciate them. Thanks in advance!
P.S. - if anyone knows how to get retroarch to save screenshots on a timely basis, that would also help!