Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resizable game icons #12646

Merged
merged 3 commits into from
Mar 2, 2020
Merged

Resizable game icons #12646

merged 3 commits into from
Mar 2, 2020

Conversation

iota97
Copy link
Contributor

@iota97 iota97 commented Feb 26, 2020

As mentioned in #12353 game icon size may end up looking too small.

Design wise I'm not sure where to place the "+" and "-" button (and there might be a better way to center the text on them than 2 spaces), it used the topBar enabling it partially for "recent game" with
+, -, and grid/list mode (icon size affect grid only).

Some screenshot on a 1080p display (the scale is a bit extreme here, it's more to give an idea)

base standard size

b increased size

I also wonder if the icon look too blurry to use this way and some better scaling might be needed.

@Abbanon
Copy link
Contributor

Abbanon commented Feb 27, 2020

What if the Texture Scaling feature (xBRZ, Hybrid, etc) could be applied to these thumbnails at increased sizes? Maybe have them fully generate as filtered .png files upon being enabled so it won't be an active filter feature that runs in the background.

@iota97
Copy link
Contributor Author

iota97 commented Feb 27, 2020

Texture Scaling would be nice, sadly I don't think I'll be able to implement it with as my limited skill.

@hrydgard
Copy link
Owner

hrydgard commented Feb 27, 2020

I think the icons can generally take a 2-3x scale but not very much more. Using a texture scaling algorithm would be an option, sure, but doesn't look that great except in special cases.

Yeah the tricky part is the UI. On PC we could support Ctrl+mousewheel which is zoom in most apps, and on mobile with multitouch, two finger drag, but there are more platforms than that, and adding buttons gets a little ugly. Maybe we could simply have yet another normal setting, with no immediate adjustment if the other options aren't available.

@iota97
Copy link
Contributor Author

iota97 commented Feb 27, 2020

Getting all the view to update seem trickier than I hoped too, currently it iterate the over the vector with the gameBrowser to call Refresh() on them all, but this miss the remote ISO screen (and maybe replace UMD too, but I'm not sure what that view is) updating the scale.

Edit:
Nevermind, overriding Draw to make it call Refresh() if scale changed worked fine, and now just change scale on g_Config will update everything automatically so binding it to other key/action should be way easier.

About the UI, I removed the top bar from recent (now is as in master), while leaving +/- button on it for all games and homebrew tabs.

@hrydgard
Copy link
Owner

Maybe this will look awkward, but you could try
screenManager()->topScreen()->RecreateViews(); to recreate everything.

@iota97
Copy link
Contributor Author

iota97 commented Feb 27, 2020

screenManager() is not in scope (missing some header?), anyway i guess Draw override will make thing easier with other binding.

@hrydgard
Copy link
Owner

hrydgard commented Feb 27, 2020

Ah I see you solved it, never mind. I'll look at this more closely later.

@Abbanon
Copy link
Contributor

Abbanon commented Feb 27, 2020

I have an idea! What if...

Instead of increasing the scale of the Thumbnail Art, just increasing the scale of the thumbnail/tappable area itself by adding an Info Box?

Here are a few examples I whipped together:
(Box highlighted in blue indicates what the cursor is currently selecting)

1x size: (keeps thumbnail art the same, adds info box underneath)
example-1

2x size: (increases thumbnail art size to 2x, adds expanded info box, gear and flag are moved to info box, Game ID added to info box)
example-2

Honestly, being able to scale Thumbnail Art and Info Box sizes independently from each other would probably be a good idea too.
So you could have the expanded 2x Info Box with just the 1x Thumbnail Arts, for example.

Does this seem like it could work?

@iota97
Copy link
Contributor Author

iota97 commented Feb 27, 2020

Info box could work, but as it's a separate thing, I think it's better to just make the current grid view scalable before adding another style.

@iota97
Copy link
Contributor Author

iota97 commented Feb 28, 2020

+ and - button will be visible in grid mode, on top bar if present or on the side otherwise:

r
l
g

@iota97 iota97 changed the title [WIP] Resizable game icons Resizable game icons Mar 1, 2020
@iota97
Copy link
Contributor Author

iota97 commented Mar 1, 2020

I'm fine with the result atm (still any suggestion is welcome on both code and UI design). I'll rebase when ui atlas change get merged.

@Abbanon
Copy link
Contributor

Abbanon commented Mar 1, 2020

It almost looks like a scaling filter is being used. Is it?

@iota97
Copy link
Contributor Author

iota97 commented Mar 1, 2020

Well if a image get scaled new pixel need a value, here should just be bilinear interpolated nothing more. I guess is just isn't nearest-neighbor, you may check a gallery here.

@Abbanon
Copy link
Contributor

Abbanon commented Mar 1, 2020

In my personal opinion, nearest-neighbour might be ideal for some users (myself included).
Would it be too much hassle if I asked for an option to "Force nearest-neighbour when scaling game icons"?

@hrydgard
Copy link
Owner

hrydgard commented Mar 1, 2020

I'm starting to think that instead of the two little plus and minus buttons, we should just make a little "menu" button that pops up a menu with the display settings for the gamelist. They could then be removed from the System settings where they don't really belong. There we could put a checkbox for filtering. The problem with nearest here is that it's only appropriate if the scale is exactly 1x, 2x etc, but due to DPI etc that will at least on mobile rarely be the case whatever you do. On Windows though if your DPI is 100% it could work...

@iota97
Copy link
Contributor Author

iota97 commented Mar 1, 2020

Might a menu like this work? With a little menu button rather than "Game list setting one" may be.

Screenshot_2020-03-01_13-00-51

Screenshot_2020-03-01_13-01-16

Might be simpler to add a new "tab" in the setting tho'

@hrydgard
Copy link
Owner

hrydgard commented Mar 1, 2020

I thought something more lightweight, like the ingame Dev menu popup or so, not a whole screen. I don't want a major new category for this, it's too much visual space for something I think few people with bother with.

@iota97
Copy link
Contributor Author

iota97 commented Mar 1, 2020

I guess this is starting to look better.

b
a

Few note:

  • There are 3 config option for grid/list mode not sure if is better to display all, only the relevant one or merge them in "global" setting.
  • Needed to change GameBrowser contructor to pass screenManager() to it.
  • Using a slider pop up would make the main screen black (I guess too many stacked popup).
  • Clear game list is still in system setting, gotta take a better look to that button logic to move it.
  • I wonder if there is a color palette option for this pop up menu style.

@hrydgard
Copy link
Owner

hrydgard commented Mar 1, 2020

Hm, yeah, didn't think about the slider popup darkening thing... Maybe need to do something about that. Anyway, getting there! I think we should probably keep the old buttons for list vs icons though, in addition to this one? maybe this one can use the gear icon for now to not clash (though should think about a better one)?

Yeah, the colors on this style of popup aren't great. Can always tweak little things like that after merge though.

@iota97
Copy link
Contributor Author

iota97 commented Mar 1, 2020

Added the old button back, changed icon with the gear one and rebased on master (I squashed commit together to reduce the conflict, I still have the old history on a local branch if needed).

@unknownbrackets
Copy link
Collaborator

I wonder why the height is filling vertically rather than wrapping content, but we can always investigate later. I think showing the settings inline here makes a lot of sense.

-[Unknown]

@iota97
Copy link
Contributor Author

iota97 commented Mar 2, 2020

Moved the clear recent button as well and some minor renaming (no reason to say show flag on game list in a game list only option).

Screenshot_2020-03-02_12-02-30

b

Edit: Fixed weight, it now wrap the content.

@hrydgard
Copy link
Owner

hrydgard commented Mar 2, 2020

Starting to look really really good! I'm happy to merge as-is and tweak the color scheme afterwards. Those popup windows really are ugly, matching the colors of Android 3.0 Honeycomb... :P

@Abbanon
Copy link
Contributor

Abbanon commented Mar 2, 2020

I would suggest keeping the gear and flags from scaling with the thumbnails, and instead keeping them at their original static size since thy're already so miniscule (32x32 and 24x14, respectively)

@iota97
Copy link
Contributor Author

iota97 commented Mar 2, 2020

I think not scaling them would be worse as they will look too small over a big icon.

@hrydgard hrydgard merged commit 777facd into hrydgard:master Mar 2, 2020
@hrydgard hrydgard added this to the v1.10.0 milestone Mar 2, 2020
@ghost
Copy link

ghost commented Mar 3, 2020

@hrydgard I can't see the last option.

Screenshot_20200303-080236_PPSSPP

@Abbanon
Copy link
Contributor

Abbanon commented Mar 3, 2020

Can confirm, under a certain window size the "Clear Recent games list" option is cut off from view. Can't scroll down to see it.

Additionally, there's a scroll bar appearing in Recent, and I'm able to scroll up/down, despite not having enough thumbnails to allow scrolling:
Untitled

Edit: The scroll bar is also cutting into/covering up the right edge of the gear icon.
Screenshot_2

@iota97
Copy link
Contributor Author

iota97 commented Mar 3, 2020

Mhhh, removing that weight caused some issues I didn't notice, my bad. Adding it back fix them, I'm not sure what's going on tho'.

@hrydgard
Copy link
Owner

hrydgard commented Mar 3, 2020

I merged your workaround, I'm gonna clean this up visually later. For now it still works pretty well.

@ghost
Copy link

ghost commented Mar 3, 2020

Arranged. Thank you!

Screenshot_20200303-123323_PPSSPP

@iota97 iota97 deleted the grid-scale branch March 6, 2020 09:54
@unknownbrackets
Copy link
Collaborator

I generally like this change, but when the window is 1x or 2x (the default), I think it looks really awkward how there's three games per row and a bunch of space to the right of them.

Obviously a bunch of the settings are related to the Recent list, but I wonder if it'd be an option to hide it on the Recent tab. Or, to put it above the game icons (like on other tabs) when we'd show less than 4 games per line.

-[Unknown]

@iota97
Copy link
Contributor Author

iota97 commented Mar 8, 2020

Putting it above will make a weird space on top sadly.

We could maye add a checkbox to hide/show the button on recent tab (both in these setting and in system one to re-enable it).

@hrydgard
Copy link
Owner

hrydgard commented Mar 8, 2020

@unknownbrackets It annoys me too, but I have a plan for that, stay tuned.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants