autobleem / AutoBleem

AutoBleem - Alternative to BleemSync/BootMenu, C++ based, GameScanner and Updater for Playstation Classic
GNU General Public License v3.0
499 stars 72 forks source link

Suggestion: Title Screens in Retroarch Section #295

Closed lampadablu closed 4 years ago

lampadablu commented 4 years ago

In my personal setup i don't have roms boxarts, but only title screens and snapshots. It's not a problem to change folder name but i'm thinking why not implement this two folder in the code?

https://github.com/autobleem/AutoBleem/blob/0a8e6cd80beb8cc8cda4b8d287ff42ee46dfe363/src/code/launcher/ps_carousel.cpp#L117

Here's my idea:

imagePath= Env::getPathToRetroarchDir() + sep + "thumbnails" + sep +
                DirEntry::getFileNameWithoutExtension((*this)->db_name) + sep +
                "Named_Boxarts" + sep + RAIntegrator::escapeName((*this)->title) + ".png";
imagePath2= Env::getPathToRetroarchDir() + sep + "thumbnails" + sep +
                DirEntry::getFileNameWithoutExtension((*this)->db_name) + sep +
                "Named_Titles" + sep + RAIntegrator::escapeName((*this)->title) + ".png";
imagePath3= Env::getPathToRetroarchDir() + sep + "thumbnails" + sep +
                DirEntry::getFileNameWithoutExtension((*this)->db_name) + sep +
                "Named_Snaps" + sep + RAIntegrator::escapeName((*this)->title) + ".png";
SDL_SetRenderTarget(renderer, nullptr);
if (DirEntry::exists(imagePath)) {
    coverPng = IMG_LoadTexture(renderer, imagePath.c_str());
}
else if (DirEntry::exists(imagePath2)) {
    coverPng = IMG_LoadTexture(renderer, imagePath2.c_str());
}
else if (DirEntry::exists(imagePath3)) {
    coverPng = IMG_LoadTexture(renderer, imagePath3.c_str());
}
else {
    cout << "boxart image NOT found for " << imagePath << endl;
    coverPng = IMG_LoadTexture(renderer, (Env::getWorkingPath() + sep + "evoimg/ra-cover.png").c_str());
}

Thanks for this software and your work!

AKA-Axanar commented 4 years ago

I'll give that a try. Thanks!

AKA-Axanar commented 4 years ago

updated gui for 0.8.5 https://drive.google.com/drive/folders/1nVyiQD5VF7wcNLcGiGFoxHj_WfCy4tdI

lampadablu commented 4 years ago

I've tried now and it works perfectly! Thanks for coding so fast :)

AKA-Axanar commented 4 years ago

thanks for the idea and the sample code.