1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-14 12:33:01 +08:00

Merge pull request #2631 from smoogipoo/compose-timeline-colours

Colourise the editor waveform
This commit is contained in:
Dean Herbert 2018-06-18 04:39:49 +09:00 committed by GitHub
commit ec81ed1c8d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4,6 +4,7 @@
using osu.Framework.Allocation; using osu.Framework.Allocation;
using osu.Framework.Audio.Track; using osu.Framework.Audio.Track;
using osu.Framework.Configuration; using osu.Framework.Configuration;
using osu.Framework.Extensions.Color4Extensions;
using osu.Framework.Graphics; using osu.Framework.Graphics;
using osu.Framework.Graphics.Audio; using osu.Framework.Graphics.Audio;
using osu.Framework.Input; using osu.Framework.Input;
@ -31,14 +32,17 @@ namespace osu.Game.Screens.Edit.Screens.Compose.Timeline
private WaveformGraph waveform; private WaveformGraph waveform;
[BackgroundDependencyLoader] [BackgroundDependencyLoader]
private void load(IBindableBeatmap beatmap, IAdjustableClock adjustableClock) private void load(IBindableBeatmap beatmap, IAdjustableClock adjustableClock, OsuColour colours)
{ {
this.adjustableClock = adjustableClock; this.adjustableClock = adjustableClock;
Child = waveform = new WaveformGraph Child = waveform = new WaveformGraph
{ {
RelativeSizeAxes = Axes.Both, RelativeSizeAxes = Axes.Both,
Colour = OsuColour.FromHex("222"), Colour = colours.Blue.Opacity(0.2f),
LowColour = colours.BlueLighter,
MidColour = colours.BlueDark,
HighColour = colours.BlueDarker,
Depth = float.MaxValue Depth = float.MaxValue
}; };