dlss-swapper icon indicating copy to clipboard operation
dlss-swapper copied to clipboard

[Feature request] GoG Support

Open beeradmoore opened this issue 4 years ago • 4 comments

Is your feature request related to a problem? Please describe. No GOG games appear.

Describe the solution you'd like Add support for scanning of games installed via GoG Galaxy

Additional context Test games - Cyberpunk 2077

beeradmoore avatar Aug 23 '21 23:08 beeradmoore

Some notes while investigating this.

C:\ProgramData\GOG.com\Galaxy\storage\data.db contains data about installed games.

Product Details View table has some useful things. productId 1207659026

stored_at 27380645

Title Theme Hospital

links

{
  "forum" : "https:\/\/www.gog.com\/forum\/theme_hospital",
  "product_card" : "https:\/\/www.gog.com\/game\/theme_hospital",
  "purchase_link" : "https:\/\/www.gog.com\/checkout\/manual\/1207659026",
  "support" : "https:\/\/www.gog.com\/support\/theme_hospital"
}

images

{
    "background": "https:\/\/images-3.gog-statics.com\/e4c3461737eed20948cb84089d716694782584beba983fb09f36c14212b75afb.jpg",
    "icon": "https:\/\/images-4.gog-statics.com\/ee3234decbd0dcec371d441a3ab5e161a8353aed589efbe5b1ba464dea83d68b.png",
    "logo": "https:\/\/images-1.gog-statics.com\/e179e3bc09e944c3d148c439b4d4af579ed24d4b3a7fbd16c1be108c8450a0af_glx_logo.jpg",
    "logo2x": "https:\/\/images-3.gog-statics.com\/e179e3bc09e944c3d148c439b4d4af579ed24d4b3a7fbd16c1be108c8450a0af_glx_logo_2x.jpg",
    "menuNotificationAv": "https:\/\/images-1.gog-statics.com\/ee3234decbd0dcec371d441a3ab5e161a8353aed589efbe5b1ba464dea83d68b_menu_notification_av.png",
    "menuNotificationAv2": "https:\/\/images-3.gog-statics.com\/ee3234decbd0dcec371d441a3ab5e161a8353aed589efbe5b1ba464dea83d68b_menu_notification_av2.png",
    "sidebarIcon": "https:\/\/images-4.gog-statics.com\/ee3234decbd0dcec371d441a3ab5e161a8353aed589efbe5b1ba464dea83d68b_sbicon.png",
    "sidebarIcon2x": "https:\/\/images-1.gog-statics.com\/ee3234decbd0dcec371d441a3ab5e161a8353aed589efbe5b1ba464dea83d68b_sbicon_2x.png"
}

InstalledBaseProducts contains the rest of the info productId 1207659026

installationPath C:\Program Files (x86)\GOG Galaxy\Games\Theme Hospital

buildId can probable be used for cache 52093441875244012

beeradmoore avatar Jan 22 '22 08:01 beeradmoore

So for the most part this is functional off on it's own branch. It looks gross as game cover images we fetch online are the wrong aspect ratio. Oddly enough there are cover images available locally that would work a lot better 🤷‍♂️

I don't know if I'll release this broken as a pre-release or if I'll fix the cover images.

The fix is to add a 'CoverImage' class which takes a IGameLibrary object as well as making a new IGame object. This would allow to load images locally as well as allow us to have our own cache of images for offline usage.

beeradmoore avatar Jun 14 '22 02:06 beeradmoore

You could possibly fetch game assets from https://www.steamgriddb.com/, you can find many that match the aspect ratio of the steam vertical grids.

MorGuux avatar Jun 14 '22 02:06 MorGuux

I had been looking at using IGDB but there are some downsides to it.

In theory the CoverImage class mentioned above could be used to allow an app setting (or even order) of where the user would want cover art from. So the user could have the option between:

  • DLSS per platform implementation
  • IGDB
  • SteamGridDB

And at that point the user could also choose if they want game thumbnails as rectangles or squares (and thinking of it game display as grid or list). At this point more interested in getting something happening but it is interesting to see how deep that idea could go.

beeradmoore avatar Jun 14 '22 03:06 beeradmoore

Issues mentioned here were resolved. We also now load images from disk if they are found rather than downloading. So we get faster loading. I hope to have this update out REAAAAL soon.

beeradmoore avatar Oct 03 '22 23:10 beeradmoore

This has been added in the v0.9.12.0 preview. Closing for now, if you have any issues with GoG compatibility please file new issues.

beeradmoore avatar Oct 09 '22 08:10 beeradmoore