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

Reduce semi-opaque layers at song select #30580

Merged
merged 3 commits into from
Nov 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions osu.Game/Screens/Select/BeatmapCarousel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1116,11 +1116,6 @@ private void updateItem(DrawableCarouselItem item, DrawableCarouselItem? parent
// adjusting the item's overall X position can cause it to become masked away when
// child items (difficulties) are still visible.
item.Header.X = offsetX(dist, visibleHalfHeight) - (parent?.X ?? 0);

// We are applying a multiplicative alpha (which is internally done by nesting an
// additional container and setting that container's alpha) such that we can
// layer alpha transformations on top.
item.SetMultiplicativeAlpha(Math.Clamp(1.75f - 1.5f * dist, 0, 1));
}

private enum PendingScrollOperation
Expand Down
2 changes: 0 additions & 2 deletions osu.Game/Screens/Select/Carousel/DrawableCarouselItem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,6 @@ protected DrawableCarouselItem()
};
}

public void SetMultiplicativeAlpha(float alpha) => Header.BorderContainer.Alpha = alpha;

protected override void LoadComplete()
{
base.LoadComplete();
Expand Down
5 changes: 2 additions & 3 deletions osu.Game/Screens/Select/FilterControl.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
using osu.Game.Rulesets.Mods;
using osu.Game.Screens.Select.Filter;
using osuTK;
using osuTK.Graphics;
using osuTK.Input;

namespace osu.Game.Screens.Select
Expand Down Expand Up @@ -97,8 +96,8 @@ private void load(OsuColour colours, OsuConfigManager config)
{
new Box
{
Colour = Color4.Black,
Alpha = 0.8f,
Colour = OsuColour.Gray(0.05f),
Alpha = 0.96f,
Width = 2,
RelativeSizeAxes = Axes.Both,
},
Expand Down
8 changes: 4 additions & 4 deletions osu.Game/Screens/Select/Footer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,11 @@
using System.Collections.Generic;
using System.Linq;
using osuTK;
using osuTK.Graphics;
using osu.Framework.Extensions.Color4Extensions;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Shapes;
using osu.Framework.Input.Events;
using osu.Game.Graphics;
using osu.Game.Graphics.UserInterface;

namespace osu.Game.Screens.Select
Expand Down Expand Up @@ -82,14 +81,15 @@ public Footer()
{
RelativeSizeAxes = Axes.Both,
Size = Vector2.One,
Colour = Color4.Black.Opacity(0.5f),
Colour = OsuColour.Gray(0.1f),
Alpha = 0.96f,
},
modeLight = new Box
{
RelativeSizeAxes = Axes.X,
Height = 3,
Position = new Vector2(0, -3),
Colour = Color4.Black,
Colour = OsuColour.Gray(0.1f),
},
new FillFlowContainer
{
Expand Down