Skip to content

Commit bacc8f1

Browse files
committed
Support for ES-DE fanart and miximage
1 parent 9b04437 commit bacc8f1

14 files changed

Lines changed: 75 additions & 23 deletions

config.ini.example

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@
8383
;innerBracketsReplace="] ["
8484
;innerParenthesesReplace=") ("
8585
;ignoreYearInFilename="false"
86+
;theInFront="false"
8687

8788
; The following is an example of configs that only affect the 'snes' platform.
8889
;[snes]

docs/CHANGELOG.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,12 @@ humans](https://keepachangelog.com).
77

88
- Added: Support for [Batocera gamelists](FRONTENDS.md#batocera) incl. fanart
99
output
10-
- Added: Support for fanart gamelist output for some [EmulationStation
10+
- Added: Support for fanart gamelist output for ES-DE and some [EmulationStation
1111
variants](CONFIGINI.md#gamelistvariants)
1212
- Added: Fanart scraping with Screenscraper-, TGDB- and Import-scraper. See flag
1313
and config option [`fanarts`](CLIHELP.md#fanarts)
14+
- Added: Support for ES-DE miximages output (aka Skyscraper artwork) with [flag
15+
miximages](CLIHELP.md#miximages)
1416
- Added: Allow more relaxed extension syntax in config options. In addition to
1517
`'*.ext'` also allow `'.ext'` and `'ext'`
1618
- Added: Accept also singular for media flags, e.g. `--flags video` additionally

docs/CLIHELP.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -468,6 +468,14 @@ When gathering data from any of the scraping modules many potential entries will
468468

469469
By default Skyscraper doesn't scrape and cache game manuals resources because not all scraping sites provide this data and also only some frontends support PDF display of these game manuals. You can enable it by using this flag. Consider setting this in [`config.ini`](CONFIGINI.md#manuals) instead.
470470

471+
#### miximages
472+
473+
This is an epheremal flag and has only an effect when used with the ES-DE frontend. The miximage feature is coming up with ES-DE 3.4.0 onwards. 'Miximage' in ES-DE is their implementation of Skyscraper's artwork processing. When you set this flag, Skyscraper's artwork file will be stored in the ES-DE miximage media folder. The ES-DE screenshots media folder will contain the plain screenshot of a game. If this flag is unset, the screenshots folder of ES-DE contains the artwork file of Skyscraper (defined by the artwork XML file), which is most likely what you want with ES-DE 3.3.0 or earlier.
474+
475+
!!! warning "Epheremal Flag for ES-DE"
476+
477+
Once the miximage of ES-DE feature has been released, this flag may be removed again from Skyscraper.
478+
471479
#### nobrackets
472480

473481
Use this flag to disable any bracket notes when generating the game list. It will disable notes such as `(Europe)` and `[AGA]` completely. This flag is only relevant when generating the game list. It makes no difference when gathering data into the resource cache. Consider setting this in [`config.ini`](CONFIGINI.md#brackets) instead.

docs/CONFIGINI.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1074,10 +1074,10 @@ Allowed in sections: Only for frontends `[emulationstation]`, `[esde]` or `[retr
10741074
By default Skyscraper doesn't scrape and cache game fanart resources because not
10751075
all scraping sites provide this data and also only some frontends support fanart
10761076
display. If enabled Skyscraper will collect game manuals for the scraping
1077-
modules that provide this data. For frontend Batocera no further option must be
1078-
set to enable the output of fanart in the gamelist and into the appropriate
1079-
folder during gamelist creation. For other EmulationStation forks where themes
1080-
support the display of fanart, see also option
1077+
modules that provide this data. For the frontends ES-DE and Batocera no further
1078+
option must be set to enable the output of fanart in the gamelist and into the
1079+
appropriate folder during gamelist creation. For other EmulationStation forks
1080+
where themes support the display of fanart, see also option
10811081
[gameListVariants](CONFIGINI.md#gamelistvariants).
10821082

10831083
Default value: false
@@ -1090,10 +1090,10 @@ Allowed in sections: `[main]`, `[<PLATFORM>]`
10901090
By default Skyscraper doesn't scrape and cache game manuals resources because
10911091
not all scraping sites provide this data and also only some frontends support
10921092
PDF display of these game manuals. If enabled Skyscraper will collect game
1093-
manuals for the scraping modules that provide this data. For frontend ES-DE and
1094-
Batocera no further option must be set to enable the output of the PDF manuals
1095-
to the appropriate folder during gamelist creation. For other EmulationStation
1096-
forks which support PDF manual display, see also option
1093+
manuals for the scraping modules that provide this data. For the frontends ES-DE
1094+
and Batocera no further option must be set to enable the output of the PDF
1095+
manuals to the appropriate folder during gamelist creation. For other
1096+
EmulationStation forks which support PDF manual display, see also option
10971097
[gameListVariants](CONFIGINI.md#gamelistvariants).
10981098

10991099
Default value: false

docs/FRONTENDS.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -75,11 +75,13 @@ highlights the differences.
7575
ROMs are expected to be in the input folder `/home/<USER>/ROMs/<PLATFORM>` for
7676
every `<PLATFORM>` you scrape.
7777

78-
Media filepaths (screenshots, marquees, videos, aso.) are not explicitly stored
79-
in the gamelist file. This is ES-DE default. However, Skyscraper will put the
80-
media files into the `downloaded_media` folder (e.g.
78+
Media filepaths (screenshots, marquees, videos, aso.) are not held in the
79+
gamelist file. This is ES-DE default. However, Skyscraper will put the media
80+
files into the `downloaded_media` folder (e.g.
8181
`~/ES-DE/downloaded_media/<PLATFORM>/screenshots/` for screenshots) from where
82-
ES-DE will pick them up. ES-DE does not support textures currently.
82+
ES-DE will pick them up. ES-DE does not support textures currently. Any manual
83+
or fanart data present in the cache will be put automagically into
84+
`~/ES-DE/downloaded_media/<PLATFORM>` where ES-DE will load it.
8385

8486
!!! tip
8587

src/cli.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -469,6 +469,8 @@ QMap<QString, QString> Cli::getSubCommandOpts(const QString subCmd) {
469469
{"fanarts",
470470
"Enables scraping and caching of fanart for the scraping modules "
471471
"that support them."},
472+
{"miximages",
473+
"Enables output of Skyscraper's artwork as ES-DE miximage."},
472474
};
473475
} else {
474476
QStringList resTypes = Cache::getAllResourceTypes();

src/compositor.cpp

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
#include "compositor.h"
2727

2828
#include "batocera.h" // TODO: Does not fit in here
29+
#include "config.h"
2930
#include "fxbalance.h"
3031
#include "fxblur.h"
3132
#include "fxbrightness.h"
@@ -289,7 +290,7 @@ void Compositor::addChildLayers(Layer &layer, QXmlStreamReader &xml) {
289290
}
290291

291292
void Compositor::saveAll(GameEntry &game, QString completeBaseName,
292-
bool isBatocera) {
293+
bool isBatocera, bool isEsde) {
293294
bool createSubfolder = false;
294295
QString fn = "/" % completeBaseName;
295296
QString subPath = getSubpath(game.path);
@@ -313,7 +314,13 @@ void Compositor::saveAll(GameEntry &game, QString completeBaseName,
313314
continue;
314315
}
315316
} else if (output.resType == "screenshot") {
316-
filename.prepend(config->screenshotsFolder);
317+
if (isEsde) {
318+
filename.prepend(Config::lexicallyNormalPath(
319+
config->screenshotsFolder % "/../miximages"));
320+
createSubfolder = true;
321+
} else {
322+
filename.prepend(config->screenshotsFolder);
323+
}
317324
if (config->skipExistingScreenshots &&
318325
QFileInfo::exists(filename)) {
319326
// set screenshotFile to generate XML element later

src/compositor.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,8 @@ class Compositor : public QObject {
4040
Compositor(Settings *config);
4141
static bool preCheckArtworkXml(const QString &artworkXml);
4242
void processXml();
43-
void saveAll(GameEntry &game, QString completeBaseName,
44-
bool isBatocera = false);
43+
void saveAll(GameEntry &game, QString completeBaseName, bool isBatocera,
44+
bool isEsde);
4545
QString getSubpath(const QString &absPath);
4646

4747
private:

src/esde.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,10 @@ inline const QString baseFolder() {
4242

4343
void Esde::setConfig(Settings *config) {
4444
this->config = config;
45-
if (config->scraper == "cache")
45+
if (config->scraper == "cache") {
4646
config->manuals = true;
47+
config->fanart = true;
48+
}
4749
}
4850

4951
QStringList Esde::extraGamelistTags(bool isFolder) {
@@ -70,3 +72,5 @@ QString Esde::getGameListFolder() {
7072
QString Esde::getMediaFolder() {
7173
return baseFolder() % "/downloaded_media/" % config->platform;
7274
}
75+
76+
QString Esde::getFanartsFolder() { return config->mediaFolder % "/fanart"; }

src/esde.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ class Esde : public EmulationStation {
3333
QString getInputFolder() override;
3434
QString getGameListFolder() override;
3535
QString getMediaFolder() override;
36+
QString getFanartsFolder() override;
3637

3738
protected:
3839
QStringList createEsVariantXml(const GameEntry &entry) override;

0 commit comments

Comments
 (0)