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

Added new scaling modes to splash screen #20541

Closed
wants to merge 1 commit into from
Closed

Added new scaling modes to splash screen #20541

wants to merge 1 commit into from

Conversation

samuelpedrajas
Copy link
Contributor

@samuelpedrajas samuelpedrajas commented Jul 28, 2018

The only way to scale the boot splash image is the option "Application/Boot Splash/fullsize" in the project settings. This PR adds 4 new ways of scaling: keep_width, keep_height, cover and expand and keeps the previous one (calling it full_size).

The old fullsize option looked like this:
fullsize_option

And I replaced it for a new option I called "scale":
new_scaling_modes

Here I show some pictures to illustrate how each scaling mode works. In each case an icon with size 64x64 is used:

Scaling Mode Horizontal (960x540) Vertical (540x960)
disabled h_fullsize_off v_fullsize_off
keep_width h_keep_width v_fullsize_on
keep_height h_fullsize_on v_keep_height
cover h_keep_width v_keep_height
expand h_expand v_expand
full_size h_fullsize_on v_fullsize_on

The last one scales in the same way as the previous "fullsize" boolean option.

I updated both rasterizer_gles2.cpp and rasterizer_gles3.cpp. I also realised that the old "fullsize" option was not working when using GLES2.

This is my first PR so any tips, suggestions, recommendations... about anything are very welcome, specially if it's code-related.

@reduz
Copy link
Member

reduz commented Aug 10, 2018

Problem with this PR is that it breaks compatibility, so it can't be merged until 4.0.. maybe adding another property like expand_mode ?

@samuelpedrajas
Copy link
Contributor Author

Sorry for the late response.

I could keep the "fullsize" property and create a new dropdown called "expand_mode" which would only take effect when the "fullsize" property is true. The dropdown could have all the options listed in the description of this PR, renaming the choice "full_size" to just "keep". Would that be fine and would that keep compatibility?

Also, I removed my fork and now the PR is shown as commited from an "unknown repository". I've been researching and it looks like I will have to make a new PR. Sorry for this! My lack of experience on GitHub... ^^'.

@samuelpedrajas
Copy link
Contributor Author

I finally opened a new PR (because as I said I can't edit this PR anymore) here: #22488. I think that now this one becomes obsolete and can be rejected.

@akien-mga
Copy link
Member

Closing as superseded by #22488.

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

Successfully merging this pull request may close these issues.

None yet

3 participants