diff options
author | Tilman M. Jaeschke | 2023-03-27 09:59:05 +0200 |
---|---|---|
committer | Tilman M. Jaeschke | 2023-03-27 09:59:05 +0200 |
commit | 08cdf6057b15ea134f4f08be76fe6444fe67f3cd (patch) | |
tree | 0dc0d97157ebb87dcad7ea77c5c80cfee4ccfe84 | |
parent | 7f64e96b802cead464d0721fd00648460f44e46e (diff) | |
download | aur-08cdf6057b15ea134f4f08be76fe6444fe67f3cd.tar.gz |
added patch to remove splash screen
-rw-r--r-- | .SRCINFO | 6 | ||||
-rw-r--r-- | PKGBUILD | 17 | ||||
-rw-r--r-- | remove_splash.patch | 78 |
3 files changed, 94 insertions, 7 deletions
@@ -1,6 +1,6 @@ pkgbase = libretro-scummvm-git pkgdesc = ScummVM core - pkgver = 140529.0c4e573ce53 + pkgver = 140558.8247aad108c pkgrel = 1 url = https://github.com/libretro/scummvm arch = x86_64 @@ -12,7 +12,9 @@ pkgbase = libretro-scummvm-git makedepends = unzip conflicts = libretro-scummvm source = git+https://github.com/libretro/scummvm.git - sha256sums = SKIP + source = remove_splash.patch + sha512sums = SKIP + sha512sums = 0252280d86140476894a475738e42827dd6371ec50b46d58f432c43ea82330b750b9965ed42d62f5e46e327109546129b2a15410dbedce308e281e55c0abbb61 pkgname = libretro-scummvm-git @@ -1,20 +1,23 @@ # Maintainer: Tilla <carlosfritz@posteo.net> pkgname=(libretro-scummvm-git libretro-scummvm-datafiles-git libretro-scummvm-coreinfo-git) -pkgver=140529.0c4e573ce53 +pkgver=140558.8247aad108c pkgrel=1 pkgdesc="ScummVM core" arch=(x86_64 aarch64) -#url=https://github.com/scummvm/scummvm url=https://github.com/libretro/scummvm license=(GPL) groups=(libretro) #depends=(libretro-core-info) makedepends=(git wget unzip) conflicts=(libretro-scummvm) -#source=(git+https://github.com/scummvm/scummvm.git) -source=(git+https://github.com/libretro/scummvm.git) -sha256sums=(SKIP) +source=(git+https://github.com/libretro/scummvm.git remove_splash.patch) +# Regarding splash screen removal, the source states: +# // Please leave the splash screen in working order for your releases, even if they're commercial. +# // This is a proper and good way to show your appreciation for our hard work over these years. +# I disagree. Forced appreciation by showing an unnecessary screen and objectively worsen the core is not a good way at all. +# I apologize to all devs that take offense. I am grateful and appreciate your work very much! +sha512sums=(SKIP 0252280d86140476894a475738e42827dd6371ec50b46d58f432c43ea82330b750b9965ed42d62f5e46e327109546129b2a15410dbedce308e281e55c0abbb61) # Where the datafiles will be installed _sysdir=/home/player/.config/retroarch/system @@ -22,6 +25,10 @@ _sysdir=/home/player/.config/retroarch/system # Who will own them (user:group) _sysown=player:player +prepare() { + patch --forward --strip=1 --input="remove_splash.patch" +} + pkgver() { cd scummvm echo $(git rev-list --count HEAD).$(git rev-parse --short HEAD) diff --git a/remove_splash.patch b/remove_splash.patch new file mode 100644 index 000000000000..80d0db62bba0 --- /dev/null +++ b/remove_splash.patch @@ -0,0 +1,78 @@ +diff --unified --recursive --text src.old/scummvm/engines/engine.cpp src.new/scummvm/engines/engine.cpp +--- src.old/scummvm/engines/engine.cpp 2023-03-27 09:28:33.498078687 +0200 ++++ src.new/scummvm/engines/engine.cpp 2023-03-27 09:29:20.918078658 +0200 +@@ -241,74 +241,8 @@ + #include "logo_data.h" + + void splashScreen() { +- Common::MemoryReadStream stream(logo_data, ARRAYSIZE(logo_data)); +- +- Image::BitmapDecoder bitmap; +- +- if (!bitmap.loadStream(stream)) { +- warning("Error loading logo file"); +- return; +- } +- + g_system->showOverlay(); +- float scaleFactor = g_system->getHiDPIScreenFactor(); +- int16 overlayWidth = g_system->getOverlayWidth(); +- int16 overlayHeight = g_system->getOverlayHeight(); +- int16 scaledW = (int16)(overlayWidth / scaleFactor); +- int16 scaledH = (int16)(overlayHeight / scaleFactor); +- +- // Fill with orange +- Graphics::Surface screen; +- screen.create(scaledW, scaledH, g_system->getOverlayFormat()); +- screen.fillRect(Common::Rect(screen.w, screen.h), screen.format.ARGBToColor(0xff, 0xcc, 0x66, 0x00)); +- +- // Print version information +- const Graphics::Font *font = FontMan.getFontByUsage(Graphics::FontManager::kConsoleFont); +- int w = font->getStringWidth(gScummVMVersionDate); +- int x = screen.w - w - 5; +- int y = screen.h - font->getFontHeight() - 5; +- font->drawString(&screen, gScummVMVersionDate, x, y, w, screen.format.ARGBToColor(0xff, 0, 0, 0)); +- +- // Scale if needed and copy to overlay +- if (screen.w != overlayWidth) { +- Graphics::Surface *scaledScreen = screen.scale(overlayWidth, overlayHeight, false); +- g_system->copyRectToOverlay(scaledScreen->getPixels(), scaledScreen->pitch, 0, 0, scaledScreen->w, scaledScreen->h); +- scaledScreen->free(); +- delete scaledScreen; +- } else +- g_system->copyRectToOverlay(screen.getPixels(), screen.pitch, 0, 0, screen.w, screen.h); +- screen.free(); +- +- // Draw logo +- Graphics::Surface *logo = bitmap.getSurface()->convertTo(g_system->getOverlayFormat(), bitmap.getPalette()); +- if (scaleFactor != 1.0f) { +- Graphics::Surface *tmp = logo->scale(int16(logo->w * scaleFactor), int16(logo->h * scaleFactor), true); +- logo->free(); +- delete logo; +- logo = tmp; +- } +- +- int lx = MAX((overlayWidth - logo->w) / 2, 0); +- int ly = MAX((overlayHeight - logo->h) / 2, 0); +- int lw = MIN<uint16>(logo->w, overlayWidth - lx); +- int lh = MIN<uint16>(logo->h, overlayHeight - ly); +- +- g_system->copyRectToOverlay(logo->getPixels(), logo->pitch, lx, ly, lw, lh); +- logo->free(); +- delete logo; +- + g_system->updateScreen(); +- +- // Delay 0.6 secs +- uint time0 = g_system->getMillis(); +- Common::Event event; +- +- // We must poll an event in order to have the window shown at least on Mac +- g_system->getEventManager()->pollEvent(event); +- +- while (time0 + 600 > g_system->getMillis()) { +- g_system->delayMillis(10); +- } + g_system->hideOverlay(); + + splash = true; |