Tormak9970 / Steam-Art-Manager

Simple and elegant Steam library customization
GNU General Public License v3.0
80 stars 2 forks source link

Cannot select all above entries in batch mode #199

Open mdeguzis opened 3 weeks ago

mdeguzis commented 3 weeks ago

Describe the bug A clear and concise description of what the bug is.

To Reproduce Steps to reproduce the behavior:

  1. Go to batch mode (bottom right)
  2. Default is all games type, cannot select "only missing"
  3. Switch to Steam type, select "only missing" - OK
  4. Boxes turn to unchecked, but batching can being (so not sure what all it's going to process). Maybe a filtering issue in the UI?

Expected behavior Only missing selection to show only what it will pull. There is no select all/none above the results (so you could unselect all and maybe just check a few of them). We need a way to check all / none yea. I understood the "missing" filter would be those that do not have capsule art (600x900), but it seems that list is the same as "ALL", but it removes the checkmarks.

Screenshots Will add soon, on my laptop :)

Logs:

For Linux, check: /home/USER/.config/dev.tormak.steam-art-manager/logs/core.log

System information (please complete the following information):

Additional information Add any other information about the problem here.

mdeguzis commented 3 weeks ago

Disregard I think, it does check the one that's truly missing. What I think happens, is it's those "covers" that are literally a shrunk down version of the wide (old style) cover in the center, and a blurred backgrounds. Would be nice to find a way to filter those, as those are the most prevalent offenders in libraries.

When I cleared the art again, I got the right "default crap cover" that's not a true 600x900 cover, and the program doesn't feel it's missing then.

image


With cleared image (clicked same button as the one below, first time it cleared it fully to this state):

image

image


With "bad cover / not a real capsule cover":

image

Title not selected

image

Tormak9970 commented 3 weeks ago

I'll look into a solution to filter those out

mdeguzis commented 3 weeks ago

Looks like the defaults are saved to ~/.steam/steam/appcache/librarycache. The logic possibly could say if

if ! grep -q <IMAGE_NAME>.<EXT> ~/.local/share/Steam/userdata/<ID>/config/grid; then
    cover_missing=true
else
    cover_missing=false
fi

Those file formats are:

i.e. Do a comparison between the grid folder (which would be "extra images") and the default library cache.

In the test case of "A virus named Tom" here, this is what exists in library cache by default:

image

That <GAME_ID>_library_600x900.jpg is the one used. It can be a full cover, e.g. A Hat in Time, or a "fake cover" like A Virus Named Tom.

image

Tormak9970 commented 3 weeks ago

Looks like the defaults are saved to ~/.steam/steam/appcache/librarycache. The logic possibly could say if


if ! grep -q <IMAGE_NAME>.<EXT> ~/.local/share/Steam/userdata/<ID>/config/grid; then

    cover_missing=true

else

    cover_missing=false

fi

Those file formats are:

  • <GAME_ID>_header.jpg

  • <GAME_ID>_icon.jpg

  • <GAME_ID>_library_600x900.jpg

  • <GAME_ID>_library_hero_blur.jpg

  • <GAME_ID>_library_hero.jpg

  • <GAME_ID>_logo.jpg

i.e. Do a comparison between the grid folder (which would be "extra images") and the default library cache.

In the test case of "A virus named Tom" here, this is what exists in library cache by default:

image

That <GAME_ID>_library_600x900.jpg is the one used. It can be a full cover, e.g. A Hat in Time, or a "fake cover" like A Virus Named Tom.

image

Its a solid idea but unfortunately that wont work. The purpose is to set all games with no grids, so that needs to take account for games with custom grids. I'm thinking maybe showing a preview or something might help when the user is making their selection

mdeguzis commented 3 weeks ago

In the meantime, I found some code and will just tinker around with VDF/SteamGridDB for fun https://github.com/mdeguzis/python-steamgriddy. Appreciate all the help!

mdeguzis commented 3 weeks ago

A fun idea I am going to tinker with (if I can figure it out lol), is doing an OCR search. It might be magically possible to just open the header image an OCR search the <ID>_library_600x900.jpg file to see if it matches. Wild Idea LOL. Going to recheck some things to see how the library cache differs from the grid folder. The grid folder just seems to override what Steam sees in the library cache folder.

mdeguzis commented 3 weeks ago

@Tormak9970 I played around with Python OCR tools. I know you probably won't use this, but it is definitely possible to make the image comparison to determine if it's the "crap default fake capsule image".

Code: https://github.com/mdeguzis/python-steamgriddy/blob/main/utils/ocr-test.py

The OCR check:

Check if source:

image

Exists in target:

image

image

It's pretty cool

Tormak9970 commented 3 weeks ago

@Tormak9970 I played around with Python OCR tools. I know you probably won't use this, but it is definitely possible to make the image comparison to determine if it's the "crap default fake capsule image".

Code: https://github.com/mdeguzis/python-steamgriddy/blob/main/utils/ocr-test.py

The OCR check:

Check if source:

image

Exists in target:

image

image

It's pretty cool

That's neat but I probably wont use it as its not really in scope and would require a performance hit and python sidecar

mdeguzis commented 3 weeks ago

No problem, just wanted to share a possible method. It didn't introduce any noticeable slowdown when processing my 700+ games (took 6 minutes total). I'll keep this to my one off tool then.