mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 11:42:56 +08:00
Merge pull request #19560 from smoogipoo/irenderer-glwrapper
Apply `IRenderer` changes
This commit is contained in:
commit
0e232d3926
@ -4,8 +4,6 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Input.Bindings;
|
||||
using osu.Game.Beatmaps;
|
||||
using osu.Game.Rulesets.Difficulty;
|
||||
@ -50,9 +48,6 @@ namespace osu.Game.Rulesets.Pippidon
|
||||
new KeyBinding(InputKey.X, PippidonAction.Button2),
|
||||
};
|
||||
|
||||
public override Drawable CreateIcon() => new Sprite
|
||||
{
|
||||
Texture = new TextureStore(new TextureLoaderStore(CreateResourceStore()), false).Get("Textures/coin"),
|
||||
};
|
||||
public override Drawable CreateIcon() => new PippidonRulesetIcon(this);
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,26 @@
|
||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||
// See the LICENCE file in the repository root for full licence text.
|
||||
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
|
||||
namespace osu.Game.Rulesets.Pippidon
|
||||
{
|
||||
public class PippidonRulesetIcon : Sprite
|
||||
{
|
||||
private readonly Ruleset ruleset;
|
||||
|
||||
public PippidonRulesetIcon(Ruleset ruleset)
|
||||
{
|
||||
this.ruleset = ruleset;
|
||||
}
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(IRenderer renderer)
|
||||
{
|
||||
Texture = new TextureStore(renderer, new TextureLoaderStore(ruleset.CreateResourceStore()), false).Get("Textures/coin");
|
||||
}
|
||||
}
|
||||
}
|
@ -4,8 +4,6 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Input.Bindings;
|
||||
using osu.Game.Beatmaps;
|
||||
using osu.Game.Rulesets.Difficulty;
|
||||
@ -47,10 +45,6 @@ namespace osu.Game.Rulesets.Pippidon
|
||||
new KeyBinding(InputKey.S, PippidonAction.MoveDown),
|
||||
};
|
||||
|
||||
public override Drawable CreateIcon() => new Sprite
|
||||
{
|
||||
Margin = new MarginPadding { Top = 3 },
|
||||
Texture = new TextureStore(new TextureLoaderStore(CreateResourceStore()), false).Get("Textures/coin"),
|
||||
};
|
||||
public override Drawable CreateIcon() => new PippidonRulesetIcon(this);
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,29 @@
|
||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||
// See the LICENCE file in the repository root for full licence text.
|
||||
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
|
||||
namespace osu.Game.Rulesets.Pippidon
|
||||
{
|
||||
public class PippidonRulesetIcon : Sprite
|
||||
{
|
||||
private readonly Ruleset ruleset;
|
||||
|
||||
public PippidonRulesetIcon(Ruleset ruleset)
|
||||
{
|
||||
this.ruleset = ruleset;
|
||||
|
||||
Margin = new MarginPadding { Top = 3 };
|
||||
}
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(IRenderer renderer)
|
||||
{
|
||||
Texture = new TextureStore(renderer, new TextureLoaderStore(ruleset.CreateResourceStore()), false).Get("Textures/coin");
|
||||
}
|
||||
}
|
||||
}
|
@ -52,7 +52,7 @@
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="ppy.osu.Game.Resources" Version="2022.722.0" />
|
||||
<PackageReference Include="ppy.osu.Framework.Android" Version="2022.730.0" />
|
||||
<PackageReference Include="ppy.osu.Framework.Android" Version="2022.805.0" />
|
||||
</ItemGroup>
|
||||
<ItemGroup Label="Transitive Dependencies">
|
||||
<!-- Realm needs to be directly referenced in all Xamarin projects, as it will not pull in its transitive dependencies otherwise. -->
|
||||
|
@ -9,7 +9,7 @@ using osu.Framework.Allocation;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Animations;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Game.Rulesets.Mania.Objects.Drawables;
|
||||
using osu.Game.Rulesets.Objects.Drawables;
|
||||
using osu.Game.Rulesets.UI.Scrolling;
|
||||
|
@ -9,7 +9,6 @@ using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Animations;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Game.Rulesets.UI.Scrolling;
|
||||
|
@ -6,7 +6,8 @@ using System.Diagnostics;
|
||||
using System.Linq;
|
||||
using Moq;
|
||||
using NUnit.Framework;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Testing;
|
||||
@ -19,6 +20,9 @@ namespace osu.Game.Rulesets.Osu.Tests
|
||||
[HeadlessTest]
|
||||
public class LegacyMainCirclePieceTest : OsuTestScene
|
||||
{
|
||||
[Resolved]
|
||||
private IRenderer renderer { get; set; } = null!;
|
||||
|
||||
private static readonly object?[][] texture_priority_cases =
|
||||
{
|
||||
// default priority lookup
|
||||
@ -76,7 +80,12 @@ namespace osu.Game.Rulesets.Osu.Tests
|
||||
skin.Setup(s => s.GetTexture(It.IsAny<string>())).CallBase();
|
||||
|
||||
skin.Setup(s => s.GetTexture(It.IsIn(textureFilenames), It.IsAny<WrapMode>(), It.IsAny<WrapMode>()))
|
||||
.Returns((string componentName, WrapMode _, WrapMode _) => new Texture(1, 1) { AssetName = componentName });
|
||||
.Returns((string componentName, WrapMode _, WrapMode _) =>
|
||||
{
|
||||
var tex = renderer.CreateTexture(1, 1);
|
||||
tex.AssetName = componentName;
|
||||
return tex;
|
||||
});
|
||||
|
||||
Child = new DependencyProvidingContainer
|
||||
{
|
||||
@ -84,7 +93,7 @@ namespace osu.Game.Rulesets.Osu.Tests
|
||||
Child = piece = new TestLegacyMainCirclePiece(priorityLookup),
|
||||
};
|
||||
|
||||
var sprites = this.ChildrenOfType<Sprite>().Where(s => s.Texture.AssetName != null).DistinctBy(s => s.Texture.AssetName).ToArray();
|
||||
var sprites = this.ChildrenOfType<Sprite>().Where(s => !string.IsNullOrEmpty(s.Texture.AssetName)).DistinctBy(s => s.Texture.AssetName).ToArray();
|
||||
Debug.Assert(sprites.Length <= 2);
|
||||
});
|
||||
|
||||
|
@ -11,7 +11,7 @@ using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Testing.Input;
|
||||
using osu.Game.Audio;
|
||||
@ -25,6 +25,9 @@ namespace osu.Game.Rulesets.Osu.Tests
|
||||
{
|
||||
public class TestSceneCursorTrail : OsuTestScene
|
||||
{
|
||||
[Resolved]
|
||||
private IRenderer renderer { get; set; }
|
||||
|
||||
[Test]
|
||||
public void TestSmoothCursorTrail()
|
||||
{
|
||||
@ -44,7 +47,7 @@ namespace osu.Game.Rulesets.Osu.Tests
|
||||
{
|
||||
createTest(() =>
|
||||
{
|
||||
var skinContainer = new LegacySkinContainer(false);
|
||||
var skinContainer = new LegacySkinContainer(renderer, false);
|
||||
var legacyCursorTrail = new LegacyCursorTrail(skinContainer);
|
||||
|
||||
skinContainer.Child = legacyCursorTrail;
|
||||
@ -58,7 +61,7 @@ namespace osu.Game.Rulesets.Osu.Tests
|
||||
{
|
||||
createTest(() =>
|
||||
{
|
||||
var skinContainer = new LegacySkinContainer(true);
|
||||
var skinContainer = new LegacySkinContainer(renderer, true);
|
||||
var legacyCursorTrail = new LegacyCursorTrail(skinContainer);
|
||||
|
||||
skinContainer.Child = legacyCursorTrail;
|
||||
@ -82,10 +85,12 @@ namespace osu.Game.Rulesets.Osu.Tests
|
||||
[Cached(typeof(ISkinSource))]
|
||||
private class LegacySkinContainer : Container, ISkinSource
|
||||
{
|
||||
private readonly IRenderer renderer;
|
||||
private readonly bool disjoint;
|
||||
|
||||
public LegacySkinContainer(bool disjoint)
|
||||
public LegacySkinContainer(IRenderer renderer, bool disjoint)
|
||||
{
|
||||
this.renderer = renderer;
|
||||
this.disjoint = disjoint;
|
||||
|
||||
RelativeSizeAxes = Axes.Both;
|
||||
@ -98,14 +103,14 @@ namespace osu.Game.Rulesets.Osu.Tests
|
||||
switch (componentName)
|
||||
{
|
||||
case "cursortrail":
|
||||
var tex = new Texture(Texture.WhitePixel.TextureGL);
|
||||
var tex = new Texture(renderer.WhitePixel);
|
||||
|
||||
if (disjoint)
|
||||
tex.ScaleAdjust = 1 / 25f;
|
||||
return tex;
|
||||
|
||||
case "cursormiddle":
|
||||
return disjoint ? null : Texture.WhitePixel;
|
||||
return disjoint ? null : renderer.WhitePixel;
|
||||
}
|
||||
|
||||
return null;
|
||||
|
@ -10,7 +10,6 @@ using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Shapes;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Input;
|
||||
|
@ -12,7 +12,6 @@ using osu.Framework.Audio;
|
||||
using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Timing;
|
||||
|
@ -9,9 +9,9 @@ using System.Runtime.InteropServices;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Extensions.EnumExtensions;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Batches;
|
||||
using osu.Framework.Graphics.OpenGL.Vertices;
|
||||
using osu.Framework.Graphics.Primitives;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Rendering.Vertices;
|
||||
using osu.Framework.Graphics.Shaders;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Input;
|
||||
@ -68,8 +68,9 @@ namespace osu.Game.Rulesets.Osu.UI.Cursor
|
||||
}
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(ShaderManager shaders)
|
||||
private void load(IRenderer renderer, ShaderManager shaders)
|
||||
{
|
||||
texture ??= renderer.WhitePixel;
|
||||
shader = shaders.Load(@"CursorTrail", FragmentShaderDescriptor.TEXTURE);
|
||||
}
|
||||
|
||||
@ -79,7 +80,7 @@ namespace osu.Game.Rulesets.Osu.UI.Cursor
|
||||
resetTime();
|
||||
}
|
||||
|
||||
private Texture texture = Texture.WhitePixel;
|
||||
private Texture texture;
|
||||
|
||||
public Texture Texture
|
||||
{
|
||||
@ -222,7 +223,7 @@ namespace osu.Game.Rulesets.Osu.UI.Cursor
|
||||
private Vector2 size;
|
||||
private Vector2 originPosition;
|
||||
|
||||
private readonly QuadBatch<TexturedTrailVertex> vertexBatch = new QuadBatch<TexturedTrailVertex>(max_sprites, 1);
|
||||
private IVertexBatch<TexturedTrailVertex> vertexBatch;
|
||||
|
||||
public TrailDrawNode(CursorTrail source)
|
||||
: base(source)
|
||||
@ -254,15 +255,17 @@ namespace osu.Game.Rulesets.Osu.UI.Cursor
|
||||
Source.parts.CopyTo(parts, 0);
|
||||
}
|
||||
|
||||
public override void Draw(Action<TexturedVertex2D> vertexAction)
|
||||
public override void Draw(IRenderer renderer)
|
||||
{
|
||||
base.Draw(vertexAction);
|
||||
base.Draw(renderer);
|
||||
|
||||
vertexBatch ??= renderer.CreateQuadBatch<TexturedTrailVertex>(max_sprites, 1);
|
||||
|
||||
shader.Bind();
|
||||
shader.GetUniform<float>("g_FadeClock").UpdateValue(ref time);
|
||||
shader.GetUniform<float>("g_FadeExponent").UpdateValue(ref fadeExponent);
|
||||
|
||||
texture.TextureGL.Bind();
|
||||
texture.Bind();
|
||||
|
||||
RectangleF textureRect = texture.GetTextureRect();
|
||||
|
||||
@ -319,7 +322,7 @@ namespace osu.Game.Rulesets.Osu.UI.Cursor
|
||||
{
|
||||
base.Dispose(isDisposing);
|
||||
|
||||
vertexBatch.Dispose();
|
||||
vertexBatch?.Dispose();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -6,8 +6,8 @@
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Game.Graphics;
|
||||
using osu.Game.Skinning;
|
||||
using osuTK.Graphics;
|
||||
|
@ -9,6 +9,7 @@ using System.Linq;
|
||||
using JetBrains.Annotations;
|
||||
using Moq;
|
||||
using NUnit.Framework;
|
||||
using osu.Framework.Graphics.Rendering.Dummy;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Game.Beatmaps;
|
||||
using osu.Game.Rulesets.Edit;
|
||||
@ -55,7 +56,7 @@ namespace osu.Game.Tests.Editing.Checks
|
||||
[Test]
|
||||
public void TestAcceptable()
|
||||
{
|
||||
var context = getContext(new Texture(1920, 1080));
|
||||
var context = getContext(new DummyRenderer().CreateTexture(1920, 1080));
|
||||
|
||||
Assert.That(check.Run(context), Is.Empty);
|
||||
}
|
||||
@ -63,7 +64,7 @@ namespace osu.Game.Tests.Editing.Checks
|
||||
[Test]
|
||||
public void TestTooHighResolution()
|
||||
{
|
||||
var context = getContext(new Texture(3840, 2160));
|
||||
var context = getContext(new DummyRenderer().CreateTexture(3840, 2160));
|
||||
|
||||
var issues = check.Run(context).ToList();
|
||||
|
||||
@ -74,7 +75,7 @@ namespace osu.Game.Tests.Editing.Checks
|
||||
[Test]
|
||||
public void TestLowResolution()
|
||||
{
|
||||
var context = getContext(new Texture(640, 480));
|
||||
var context = getContext(new DummyRenderer().CreateTexture(640, 480));
|
||||
|
||||
var issues = check.Run(context).ToList();
|
||||
|
||||
@ -85,7 +86,7 @@ namespace osu.Game.Tests.Editing.Checks
|
||||
[Test]
|
||||
public void TestTooLowResolution()
|
||||
{
|
||||
var context = getContext(new Texture(100, 100));
|
||||
var context = getContext(new DummyRenderer().CreateTexture(100, 100));
|
||||
|
||||
var issues = check.Run(context).ToList();
|
||||
|
||||
@ -96,7 +97,7 @@ namespace osu.Game.Tests.Editing.Checks
|
||||
[Test]
|
||||
public void TestTooUncompressed()
|
||||
{
|
||||
var context = getContext(new Texture(1920, 1080), new MemoryStream(new byte[1024 * 1024 * 3]));
|
||||
var context = getContext(new DummyRenderer().CreateTexture(1920, 1080), new MemoryStream(new byte[1024 * 1024 * 3]));
|
||||
|
||||
var issues = check.Run(context).ToList();
|
||||
|
||||
@ -107,7 +108,7 @@ namespace osu.Game.Tests.Editing.Checks
|
||||
[Test]
|
||||
public void TestStreamClosed()
|
||||
{
|
||||
var background = new Texture(1920, 1080);
|
||||
var background = new DummyRenderer().CreateTexture(1920, 1080);
|
||||
var stream = new Mock<MemoryStream>(new byte[1024 * 1024]);
|
||||
|
||||
var context = getContext(background, stream.Object);
|
||||
|
@ -10,7 +10,6 @@ using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Testing;
|
||||
using osu.Game.Audio;
|
||||
|
@ -11,8 +11,10 @@ using NUnit.Framework;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Audio;
|
||||
using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.IO.Stores;
|
||||
using osu.Framework.Platform;
|
||||
using osu.Framework.Testing;
|
||||
using osu.Game.Audio;
|
||||
using osu.Game.Configuration;
|
||||
@ -36,6 +38,9 @@ namespace osu.Game.Tests.Gameplay
|
||||
[Resolved]
|
||||
private OsuConfigManager config { get; set; }
|
||||
|
||||
[Resolved]
|
||||
private GameHost host { get; set; }
|
||||
|
||||
[Test]
|
||||
public void TestRetrieveTopLevelSample()
|
||||
{
|
||||
@ -202,6 +207,7 @@ namespace osu.Game.Tests.Gameplay
|
||||
|
||||
#region IResourceStorageProvider
|
||||
|
||||
public IRenderer Renderer => host.Renderer;
|
||||
public AudioManager AudioManager => Audio;
|
||||
public IResourceStore<byte[]> Files => null;
|
||||
public new IResourceStore<byte[]> Resources => base.Resources;
|
||||
|
@ -11,7 +11,7 @@ using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Animations;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Testing;
|
||||
using osu.Framework.Timing;
|
||||
@ -27,6 +27,9 @@ namespace osu.Game.Tests.NonVisual.Skinning
|
||||
private const string animation_name = "animation";
|
||||
private const int frame_count = 6;
|
||||
|
||||
[Resolved]
|
||||
private IRenderer renderer { get; set; }
|
||||
|
||||
[Cached(typeof(IAnimationTimeReference))]
|
||||
private TestAnimationTimeReference animationTimeReference = new TestAnimationTimeReference();
|
||||
|
||||
@ -35,9 +38,12 @@ namespace osu.Game.Tests.NonVisual.Skinning
|
||||
[Test]
|
||||
public void TestAnimationTimeReferenceChange()
|
||||
{
|
||||
ISkin skin = new TestSkin();
|
||||
AddStep("get animation", () =>
|
||||
{
|
||||
ISkin skin = new TestSkin(renderer);
|
||||
Add(animation = (TextureAnimation)skin.GetAnimation(animation_name, true, false));
|
||||
});
|
||||
|
||||
AddStep("get animation", () => Add(animation = (TextureAnimation)skin.GetAnimation(animation_name, true, false)));
|
||||
AddAssert("frame count correct", () => animation.FrameCount == frame_count);
|
||||
assertPlaybackPosition(0);
|
||||
|
||||
@ -55,9 +61,16 @@ namespace osu.Game.Tests.NonVisual.Skinning
|
||||
{
|
||||
private static readonly string[] lookup_names = Enumerable.Range(0, frame_count).Select(frame => $"{animation_name}-{frame}").ToArray();
|
||||
|
||||
private readonly IRenderer renderer;
|
||||
|
||||
public TestSkin(IRenderer renderer)
|
||||
{
|
||||
this.renderer = renderer;
|
||||
}
|
||||
|
||||
public Texture GetTexture(string componentName, WrapMode wrapModeS, WrapMode wrapModeT)
|
||||
{
|
||||
return lookup_names.Contains(componentName) ? Texture.WhitePixel : null;
|
||||
return lookup_names.Contains(componentName) ? renderer.WhitePixel : null;
|
||||
}
|
||||
|
||||
public Drawable GetDrawableComponent(ISkinComponent component) => throw new NotSupportedException();
|
||||
|
@ -11,6 +11,8 @@ using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using NUnit.Framework;
|
||||
using osu.Framework.Audio;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Rendering.Dummy;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.IO.Stores;
|
||||
using osu.Game.Database;
|
||||
@ -141,6 +143,7 @@ namespace osu.Game.Tests.NonVisual.Skinning
|
||||
this.textureStore = textureStore;
|
||||
}
|
||||
|
||||
public IRenderer Renderer => new DummyRenderer();
|
||||
public AudioManager AudioManager => null;
|
||||
public IResourceStore<byte[]> Files => null;
|
||||
public IResourceStore<byte[]> Resources => null;
|
||||
|
@ -15,11 +15,12 @@ using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Shaders;
|
||||
using osu.Framework.Graphics.Shapes;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.IO.Stores;
|
||||
using osu.Framework.Platform;
|
||||
using osu.Framework.Testing;
|
||||
using osu.Game.Rulesets.Osu;
|
||||
using osu.Game.Rulesets.UI;
|
||||
@ -77,9 +78,9 @@ namespace osu.Game.Tests.Rulesets
|
||||
{
|
||||
var dependencies = new DependencyContainer(base.CreateChildDependencies(parent));
|
||||
|
||||
dependencies.CacheAs<TextureStore>(ParentTextureStore = new TestTextureStore());
|
||||
dependencies.CacheAs<TextureStore>(ParentTextureStore = new TestTextureStore(parent.Get<GameHost>().Renderer));
|
||||
dependencies.CacheAs<ISampleStore>(ParentSampleStore = new TestSampleStore());
|
||||
dependencies.CacheAs<ShaderManager>(ParentShaderManager = new TestShaderManager());
|
||||
dependencies.CacheAs<ShaderManager>(ParentShaderManager = new TestShaderManager(parent.Get<GameHost>().Renderer));
|
||||
|
||||
return new DrawableRulesetDependencies(new OsuRuleset(), dependencies);
|
||||
}
|
||||
@ -95,6 +96,11 @@ namespace osu.Game.Tests.Rulesets
|
||||
|
||||
private class TestTextureStore : TextureStore
|
||||
{
|
||||
public TestTextureStore(IRenderer renderer)
|
||||
: base(renderer)
|
||||
{
|
||||
}
|
||||
|
||||
public override Texture Get(string name, WrapMode wrapModeS, WrapMode wrapModeT) => null;
|
||||
|
||||
public bool IsDisposed { get; private set; }
|
||||
@ -148,8 +154,8 @@ namespace osu.Game.Tests.Rulesets
|
||||
|
||||
private class TestShaderManager : ShaderManager
|
||||
{
|
||||
public TestShaderManager()
|
||||
: base(new ResourceStore<byte[]>())
|
||||
public TestShaderManager(IRenderer renderer)
|
||||
: base(renderer, new ResourceStore<byte[]>())
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -10,7 +10,6 @@ using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Testing;
|
||||
using osu.Game.Audio;
|
||||
|
@ -7,7 +7,6 @@ using System.Linq;
|
||||
using NUnit.Framework;
|
||||
using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.IO.Stores;
|
||||
using osu.Game.Audio;
|
||||
|
@ -10,7 +10,6 @@ using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Testing;
|
||||
using osu.Game.Audio;
|
||||
|
@ -13,7 +13,6 @@ using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Testing;
|
||||
using osu.Game.Audio;
|
||||
|
@ -6,10 +6,11 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using NUnit.Framework;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Testing;
|
||||
using osu.Game.Audio;
|
||||
@ -21,6 +22,9 @@ namespace osu.Game.Tests.Skins
|
||||
[HeadlessTest]
|
||||
public class TestSceneSkinProvidingContainer : OsuTestScene
|
||||
{
|
||||
[Resolved]
|
||||
private IRenderer renderer { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Ensures that the first inserted skin after resetting (via source change)
|
||||
/// is always prioritised over others when providing the same resource.
|
||||
@ -35,7 +39,7 @@ namespace osu.Game.Tests.Skins
|
||||
{
|
||||
var sources = new List<TestSkin>();
|
||||
for (int i = 0; i < 10; i++)
|
||||
sources.Add(new TestSkin());
|
||||
sources.Add(new TestSkin(renderer));
|
||||
|
||||
mostPrioritisedSource = sources.First();
|
||||
|
||||
@ -76,12 +80,19 @@ namespace osu.Game.Tests.Skins
|
||||
{
|
||||
public const string TEXTURE_NAME = "virtual-texture";
|
||||
|
||||
private readonly IRenderer renderer;
|
||||
|
||||
public TestSkin(IRenderer renderer)
|
||||
{
|
||||
this.renderer = renderer;
|
||||
}
|
||||
|
||||
public Drawable GetDrawableComponent(ISkinComponent component) => throw new System.NotImplementedException();
|
||||
|
||||
public Texture GetTexture(string componentName, WrapMode wrapModeS, WrapMode wrapModeT)
|
||||
{
|
||||
if (componentName == TEXTURE_NAME)
|
||||
return Texture.WhitePixel;
|
||||
return renderer.WhitePixel;
|
||||
|
||||
return null;
|
||||
}
|
||||
|
@ -12,7 +12,7 @@ using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Extensions;
|
||||
using osu.Framework.Extensions.ObjectExtensions;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Rendering.Dummy;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.IO.Stores;
|
||||
using osu.Framework.Testing;
|
||||
@ -55,6 +55,7 @@ namespace osu.Game.Tests.Skins
|
||||
lookedUpFileNames = new List<string>();
|
||||
mockResourceProvider = new Mock<IStorageResourceProvider>();
|
||||
mockResourceProvider.Setup(m => m.AudioManager).Returns(Audio);
|
||||
mockResourceProvider.Setup(m => m.Renderer).Returns(new DummyRenderer());
|
||||
mockResourceStore = new Mock<IResourceStore<byte[]>>();
|
||||
mockResourceStore.Setup(r => r.Get(It.IsAny<string>()))
|
||||
.Callback<string>(n => lookedUpFileNames.Add(n))
|
||||
|
@ -10,6 +10,7 @@ using osu.Framework.Allocation;
|
||||
using osu.Framework.Audio;
|
||||
using osu.Framework.Audio.Track;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Screens;
|
||||
using osu.Framework.Testing;
|
||||
@ -43,6 +44,9 @@ namespace osu.Game.Tests.Visual.Background
|
||||
[Resolved]
|
||||
private OsuConfigManager config { get; set; }
|
||||
|
||||
[Resolved]
|
||||
private IRenderer renderer { get; set; }
|
||||
|
||||
[SetUpSteps]
|
||||
public void SetUpSteps()
|
||||
{
|
||||
@ -245,7 +249,7 @@ namespace osu.Game.Tests.Visual.Background
|
||||
Id = API.LocalUser.Value.Id + 1,
|
||||
});
|
||||
|
||||
private WorkingBeatmap createTestWorkingBeatmapWithUniqueBackground() => new UniqueBackgroundTestWorkingBeatmap(Audio);
|
||||
private WorkingBeatmap createTestWorkingBeatmapWithUniqueBackground() => new UniqueBackgroundTestWorkingBeatmap(renderer, Audio);
|
||||
private WorkingBeatmap createTestWorkingBeatmapWithStoryboard() => new TestWorkingBeatmapWithStoryboard(Audio);
|
||||
|
||||
private class TestBackgroundScreenDefault : BackgroundScreenDefault
|
||||
@ -274,12 +278,15 @@ namespace osu.Game.Tests.Visual.Background
|
||||
|
||||
private class UniqueBackgroundTestWorkingBeatmap : TestWorkingBeatmap
|
||||
{
|
||||
public UniqueBackgroundTestWorkingBeatmap(AudioManager audioManager)
|
||||
private readonly IRenderer renderer;
|
||||
|
||||
public UniqueBackgroundTestWorkingBeatmap(IRenderer renderer, AudioManager audioManager)
|
||||
: base(new Beatmap(), null, audioManager)
|
||||
{
|
||||
this.renderer = renderer;
|
||||
}
|
||||
|
||||
protected override Texture GetBackground() => new Texture(1, 1);
|
||||
protected override Texture GetBackground() => renderer.CreateTexture(1, 1);
|
||||
}
|
||||
|
||||
private class TestWorkingBeatmapWithStoryboard : TestWorkingBeatmap
|
||||
|
@ -10,7 +10,7 @@ using NUnit.Framework;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Game.Configuration;
|
||||
using osu.Game.Graphics.Backgrounds;
|
||||
@ -28,11 +28,9 @@ namespace osu.Game.Tests.Visual.Background
|
||||
[Resolved]
|
||||
private SessionStatics statics { get; set; }
|
||||
|
||||
[Cached(typeof(LargeTextureStore))]
|
||||
private LookupLoggingTextureStore textureStore = new LookupLoggingTextureStore();
|
||||
|
||||
private DummyAPIAccess dummyAPI => (DummyAPIAccess)API;
|
||||
|
||||
private LookupLoggingTextureStore textureStore;
|
||||
private SeasonalBackgroundLoader backgroundLoader;
|
||||
private Container backgroundContainer;
|
||||
|
||||
@ -45,15 +43,32 @@ namespace osu.Game.Tests.Visual.Background
|
||||
"Backgrounds/bg3"
|
||||
};
|
||||
|
||||
protected override IReadOnlyDependencyContainer CreateChildDependencies(IReadOnlyDependencyContainer parent)
|
||||
{
|
||||
var dependencies = new DependencyContainer(base.CreateChildDependencies(parent));
|
||||
|
||||
textureStore = new LookupLoggingTextureStore(dependencies.Get<IRenderer>());
|
||||
dependencies.CacheAs(typeof(LargeTextureStore), textureStore);
|
||||
|
||||
return dependencies;
|
||||
}
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(LargeTextureStore wrappedStore)
|
||||
{
|
||||
textureStore.AddStore(wrappedStore);
|
||||
|
||||
Add(backgroundContainer = new Container
|
||||
Child = new DependencyProvidingContainer
|
||||
{
|
||||
RelativeSizeAxes = Axes.Both
|
||||
});
|
||||
CachedDependencies = new (Type, object)[]
|
||||
{
|
||||
(typeof(LargeTextureStore), textureStore)
|
||||
},
|
||||
Child = backgroundContainer = new Container
|
||||
{
|
||||
RelativeSizeAxes = Axes.Both
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
[SetUp]
|
||||
@ -193,6 +208,11 @@ namespace osu.Game.Tests.Visual.Background
|
||||
{
|
||||
public List<string> PerformedLookups { get; } = new List<string>();
|
||||
|
||||
public LookupLoggingTextureStore(IRenderer renderer)
|
||||
: base(renderer)
|
||||
{
|
||||
}
|
||||
|
||||
public override Texture Get(string name, WrapMode wrapModeS, WrapMode wrapModeT)
|
||||
{
|
||||
PerformedLookups.Add(name);
|
||||
|
@ -13,7 +13,6 @@ using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Shapes;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Game.Audio;
|
||||
|
@ -13,7 +13,6 @@ using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Audio;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Testing;
|
||||
using osu.Game.Audio;
|
||||
|
@ -9,6 +9,8 @@ using System.Linq;
|
||||
using JetBrains.Annotations;
|
||||
using osu.Framework.Audio;
|
||||
using osu.Framework.Audio.Track;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Rendering.Dummy;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.IO.Stores;
|
||||
using osu.Framework.Lists;
|
||||
@ -56,7 +58,7 @@ namespace osu.Game.Beatmaps
|
||||
this.resources = resources;
|
||||
this.host = host;
|
||||
this.files = files;
|
||||
largeTextureStore = new LargeTextureStore(host?.CreateTextureLoaderStore(files));
|
||||
largeTextureStore = new LargeTextureStore(host?.Renderer ?? new DummyRenderer(), host?.CreateTextureLoaderStore(files));
|
||||
this.trackStore = trackStore;
|
||||
}
|
||||
|
||||
@ -110,6 +112,7 @@ namespace osu.Game.Beatmaps
|
||||
|
||||
TextureStore IBeatmapResourceProvider.LargeTextureStore => largeTextureStore;
|
||||
ITrackStore IBeatmapResourceProvider.Tracks => trackStore;
|
||||
IRenderer IStorageResourceProvider.Renderer => host?.Renderer ?? new DummyRenderer();
|
||||
AudioManager IStorageResourceProvider.AudioManager => audioManager;
|
||||
RealmAccess IStorageResourceProvider.RealmAccess => null;
|
||||
IResourceStore<byte[]> IStorageResourceProvider.Files => files;
|
||||
|
@ -14,9 +14,8 @@ using osu.Framework.Graphics.Colour;
|
||||
using osu.Framework.Graphics.Primitives;
|
||||
using osu.Framework.Allocation;
|
||||
using System.Collections.Generic;
|
||||
using osu.Framework.Graphics.Batches;
|
||||
using osu.Framework.Graphics.OpenGL.Buffers;
|
||||
using osu.Framework.Graphics.OpenGL.Vertices;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Rendering.Vertices;
|
||||
using osu.Framework.Lists;
|
||||
|
||||
namespace osu.Game.Graphics.Backgrounds
|
||||
@ -88,7 +87,7 @@ namespace osu.Game.Graphics.Backgrounds
|
||||
|
||||
private Random stableRandom;
|
||||
private IShader shader;
|
||||
private readonly Texture texture;
|
||||
private Texture texture;
|
||||
|
||||
/// <summary>
|
||||
/// Construct a new triangle visualisation.
|
||||
@ -98,13 +97,12 @@ namespace osu.Game.Graphics.Backgrounds
|
||||
{
|
||||
if (seed != null)
|
||||
stableRandom = new Random(seed.Value);
|
||||
|
||||
texture = Texture.WhitePixel;
|
||||
}
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(ShaderManager shaders)
|
||||
private void load(IRenderer renderer, ShaderManager shaders)
|
||||
{
|
||||
texture = renderer.WhitePixel;
|
||||
shader = shaders.Load(VertexShaderDescriptor.TEXTURE_2, FragmentShaderDescriptor.TEXTURE_ROUNDED);
|
||||
}
|
||||
|
||||
@ -184,8 +182,8 @@ namespace osu.Game.Graphics.Backgrounds
|
||||
|
||||
private void addTriangles(bool randomY)
|
||||
{
|
||||
// limited by the maximum size of QuadVertexBuffer for safety.
|
||||
const int max_triangles = QuadVertexBuffer<TexturedVertex2D>.MAX_QUADS;
|
||||
// Limited by the maximum size of QuadVertexBuffer for safety.
|
||||
const int max_triangles = ushort.MaxValue / (IRenderer.VERTICES_PER_QUAD + 2);
|
||||
|
||||
AimCount = (int)Math.Min(max_triangles, (DrawWidth * DrawHeight * 0.002f / (triangleScale * triangleScale) * SpawnRatio));
|
||||
|
||||
@ -251,7 +249,7 @@ namespace osu.Game.Graphics.Backgrounds
|
||||
private readonly List<TriangleParticle> parts = new List<TriangleParticle>();
|
||||
private Vector2 size;
|
||||
|
||||
private QuadBatch<TexturedVertex2D> vertexBatch;
|
||||
private IVertexBatch<TexturedVertex2D> vertexBatch;
|
||||
|
||||
public TrianglesDrawNode(Triangles source)
|
||||
: base(source)
|
||||
@ -270,14 +268,14 @@ namespace osu.Game.Graphics.Backgrounds
|
||||
parts.AddRange(Source.parts);
|
||||
}
|
||||
|
||||
public override void Draw(Action<TexturedVertex2D> vertexAction)
|
||||
public override void Draw(IRenderer renderer)
|
||||
{
|
||||
base.Draw(vertexAction);
|
||||
base.Draw(renderer);
|
||||
|
||||
if (Source.AimCount > 0 && (vertexBatch == null || vertexBatch.Size != Source.AimCount))
|
||||
{
|
||||
vertexBatch?.Dispose();
|
||||
vertexBatch = new QuadBatch<TexturedVertex2D>(Source.AimCount, 1);
|
||||
vertexBatch = renderer.CreateQuadBatch<TexturedVertex2D>(Source.AimCount, 1);
|
||||
}
|
||||
|
||||
shader.Bind();
|
||||
@ -297,7 +295,7 @@ namespace osu.Game.Graphics.Backgrounds
|
||||
ColourInfo colourInfo = DrawColourInfo.Colour;
|
||||
colourInfo.ApplyChild(particle.Colour);
|
||||
|
||||
DrawTriangle(
|
||||
renderer.DrawTriangle(
|
||||
texture,
|
||||
triangle,
|
||||
colourInfo,
|
||||
|
@ -5,7 +5,7 @@
|
||||
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using osu.Framework.Graphics.OpenGL.Vertices;
|
||||
using osu.Framework.Graphics.Rendering.Vertices;
|
||||
using osuTK;
|
||||
using osuTK.Graphics;
|
||||
using osuTK.Graphics.ES30;
|
||||
|
@ -6,8 +6,8 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.OpenGL.Vertices;
|
||||
using osu.Framework.Graphics.Primitives;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Utils;
|
||||
@ -89,7 +89,7 @@ namespace osu.Game.Graphics
|
||||
currentTime = source.Time.Current;
|
||||
}
|
||||
|
||||
protected override void Blit(Action<TexturedVertex2D> vertexAction)
|
||||
protected override void Blit(IRenderer renderer)
|
||||
{
|
||||
double time = currentTime - startTime;
|
||||
|
||||
@ -112,9 +112,9 @@ namespace osu.Game.Graphics
|
||||
Vector2Extensions.Transform(rect.BottomRight, DrawInfo.Matrix)
|
||||
);
|
||||
|
||||
DrawQuad(Texture, quad, DrawColourInfo.Colour.MultiplyAlpha(alpha), null, vertexAction,
|
||||
new Vector2(InflationAmount.X / DrawRectangle.Width, InflationAmount.Y / DrawRectangle.Height),
|
||||
null, TextureCoords);
|
||||
renderer.DrawQuad(Texture, quad, DrawColourInfo.Colour.MultiplyAlpha(alpha),
|
||||
inflationPercentage: new Vector2(InflationAmount.X / DrawRectangle.Width, InflationAmount.Y / DrawRectangle.Height),
|
||||
textureCoords: TextureCoords);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -7,8 +7,8 @@ using System;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Extensions.EnumExtensions;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.OpenGL.Vertices;
|
||||
using osu.Framework.Graphics.Primitives;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Utils;
|
||||
@ -107,7 +107,7 @@ namespace osu.Game.Graphics
|
||||
sourceSize = Source.DrawSize;
|
||||
}
|
||||
|
||||
protected override void Blit(Action<TexturedVertex2D> vertexAction)
|
||||
protected override void Blit(IRenderer renderer)
|
||||
{
|
||||
foreach (var p in particles)
|
||||
{
|
||||
@ -136,9 +136,9 @@ namespace osu.Game.Graphics
|
||||
transformPosition(rect.BottomRight, rect.Centre, angle)
|
||||
);
|
||||
|
||||
DrawQuad(Texture, quad, DrawColourInfo.Colour.MultiplyAlpha(alpha), null, vertexAction,
|
||||
new Vector2(InflationAmount.X / DrawRectangle.Width, InflationAmount.Y / DrawRectangle.Height),
|
||||
null, TextureCoords);
|
||||
renderer.DrawQuad(Texture, quad, DrawColourInfo.Colour.MultiplyAlpha(alpha),
|
||||
inflationPercentage: new Vector2(InflationAmount.X / DrawRectangle.Width, InflationAmount.Y / DrawRectangle.Height),
|
||||
textureCoords: TextureCoords);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -3,10 +3,9 @@
|
||||
|
||||
#nullable disable
|
||||
|
||||
using System;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.OpenGL.Vertices;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Shaders;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
|
||||
@ -57,11 +56,11 @@ namespace osu.Game.Graphics.Sprites
|
||||
progress = source.animationProgress;
|
||||
}
|
||||
|
||||
protected override void Blit(Action<TexturedVertex2D> vertexAction)
|
||||
protected override void Blit(IRenderer renderer)
|
||||
{
|
||||
Shader.GetUniform<float>("progress").UpdateValue(ref progress);
|
||||
GetAppropriateShader(renderer).GetUniform<float>("progress").UpdateValue(ref progress);
|
||||
|
||||
base.Blit(vertexAction);
|
||||
base.Blit(renderer);
|
||||
}
|
||||
|
||||
protected override bool CanDrawOpaqueInterior => false;
|
||||
|
@ -1,9 +1,8 @@
|
||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
||||
// See the LICENCE file in the repository root for full licence text.
|
||||
|
||||
#nullable disable
|
||||
|
||||
using osu.Framework.Audio;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.IO.Stores;
|
||||
using osu.Game.Database;
|
||||
@ -12,10 +11,15 @@ namespace osu.Game.IO
|
||||
{
|
||||
public interface IStorageResourceProvider
|
||||
{
|
||||
/// <summary>
|
||||
/// The game renderer.
|
||||
/// </summary>
|
||||
IRenderer Renderer { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Retrieve the game-wide audio manager.
|
||||
/// </summary>
|
||||
AudioManager AudioManager { get; }
|
||||
AudioManager? AudioManager { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Access game-wide user files.
|
||||
|
@ -248,7 +248,7 @@ namespace osu.Game
|
||||
|
||||
dependencies.CacheAs(Storage);
|
||||
|
||||
var largeStore = new LargeTextureStore(Host.CreateTextureLoaderStore(new NamespacedResourceStore<byte[]>(Resources, @"Textures")));
|
||||
var largeStore = new LargeTextureStore(Host.Renderer, Host.CreateTextureLoaderStore(new NamespacedResourceStore<byte[]>(Resources, @"Textures")));
|
||||
largeStore.AddTextureSource(Host.CreateTextureLoaderStore(new OnlineStore()));
|
||||
dependencies.Cache(largeStore);
|
||||
|
||||
|
@ -6,12 +6,11 @@ using System.Collections.Generic;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Batches;
|
||||
using osu.Framework.Graphics.OpenGL.Vertices;
|
||||
using osu.Framework.Graphics.Primitives;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Rendering.Vertices;
|
||||
using osu.Framework.Graphics.Shaders;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Game.Beatmaps.Timing;
|
||||
using osu.Game.Configuration;
|
||||
using osu.Game.Graphics;
|
||||
@ -211,17 +210,12 @@ namespace osu.Game.Rulesets.Mods
|
||||
private Vector2 flashlightSize;
|
||||
private float flashlightDim;
|
||||
|
||||
private readonly VertexBatch<PositionAndColourVertex> quadBatch = new QuadBatch<PositionAndColourVertex>(1, 1);
|
||||
private readonly Action<TexturedVertex2D> addAction;
|
||||
private IVertexBatch<PositionAndColourVertex>? quadBatch;
|
||||
private Action<TexturedVertex2D>? addAction;
|
||||
|
||||
public FlashlightDrawNode(Flashlight source)
|
||||
: base(source)
|
||||
{
|
||||
addAction = v => quadBatch.Add(new PositionAndColourVertex
|
||||
{
|
||||
Position = v.Position,
|
||||
Colour = v.Colour
|
||||
});
|
||||
}
|
||||
|
||||
public override void ApplyState()
|
||||
@ -235,9 +229,19 @@ namespace osu.Game.Rulesets.Mods
|
||||
flashlightDim = Source.FlashlightDim;
|
||||
}
|
||||
|
||||
public override void Draw(Action<TexturedVertex2D> vertexAction)
|
||||
public override void Draw(IRenderer renderer)
|
||||
{
|
||||
base.Draw(vertexAction);
|
||||
base.Draw(renderer);
|
||||
|
||||
if (quadBatch == null)
|
||||
{
|
||||
quadBatch = renderer.CreateQuadBatch<PositionAndColourVertex>(1, 1);
|
||||
addAction = v => quadBatch.Add(new PositionAndColourVertex
|
||||
{
|
||||
Position = v.Position,
|
||||
Colour = v.Colour
|
||||
});
|
||||
}
|
||||
|
||||
shader.Bind();
|
||||
|
||||
@ -245,7 +249,7 @@ namespace osu.Game.Rulesets.Mods
|
||||
shader.GetUniform<Vector2>("flashlightSize").UpdateValue(ref flashlightSize);
|
||||
shader.GetUniform<float>("flashlightDim").UpdateValue(ref flashlightDim);
|
||||
|
||||
DrawQuad(Texture.WhitePixel, screenSpaceDrawQuad, DrawColourInfo.Colour, vertexAction: addAction);
|
||||
renderer.DrawQuad(renderer.WhitePixel, screenSpaceDrawQuad, DrawColourInfo.Colour, vertexAction: addAction);
|
||||
|
||||
shader.Unbind();
|
||||
}
|
||||
@ -253,7 +257,7 @@ namespace osu.Game.Rulesets.Mods
|
||||
protected override void Dispose(bool isDisposing)
|
||||
{
|
||||
base.Dispose(isDisposing);
|
||||
quadBatch.Dispose();
|
||||
quadBatch?.Dispose();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -12,7 +12,7 @@ using osu.Framework.Allocation;
|
||||
using osu.Framework.Audio;
|
||||
using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Shaders;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.IO.Stores;
|
||||
@ -55,15 +55,17 @@ namespace osu.Game.Rulesets.UI
|
||||
|
||||
if (resources != null)
|
||||
{
|
||||
TextureStore = new TextureStore(parent.Get<GameHost>().CreateTextureLoaderStore(new NamespacedResourceStore<byte[]>(resources, @"Textures")));
|
||||
CacheAs(TextureStore = new FallbackTextureStore(TextureStore, parent.Get<TextureStore>()));
|
||||
var host = parent.Get<GameHost>();
|
||||
|
||||
TextureStore = new TextureStore(host.Renderer, parent.Get<GameHost>().CreateTextureLoaderStore(new NamespacedResourceStore<byte[]>(resources, @"Textures")));
|
||||
CacheAs(TextureStore = new FallbackTextureStore(host.Renderer, TextureStore, parent.Get<TextureStore>()));
|
||||
|
||||
SampleStore = parent.Get<AudioManager>().GetSampleStore(new NamespacedResourceStore<byte[]>(resources, @"Samples"));
|
||||
SampleStore.PlaybackConcurrency = OsuGameBase.SAMPLE_CONCURRENCY;
|
||||
CacheAs(SampleStore = new FallbackSampleStore(SampleStore, parent.Get<ISampleStore>()));
|
||||
|
||||
ShaderManager = new ShaderManager(new NamespacedResourceStore<byte[]>(resources, @"Shaders"));
|
||||
CacheAs(ShaderManager = new FallbackShaderManager(ShaderManager, parent.Get<ShaderManager>()));
|
||||
ShaderManager = new ShaderManager(host.Renderer, new NamespacedResourceStore<byte[]>(resources, @"Shaders"));
|
||||
CacheAs(ShaderManager = new FallbackShaderManager(host.Renderer, ShaderManager, parent.Get<ShaderManager>()));
|
||||
}
|
||||
|
||||
RulesetConfigManager = parent.Get<IRulesetConfigCache>().GetConfigFor(ruleset);
|
||||
@ -170,7 +172,8 @@ namespace osu.Game.Rulesets.UI
|
||||
private readonly TextureStore primary;
|
||||
private readonly TextureStore fallback;
|
||||
|
||||
public FallbackTextureStore(TextureStore primary, TextureStore fallback)
|
||||
public FallbackTextureStore(IRenderer renderer, TextureStore primary, TextureStore fallback)
|
||||
: base(renderer)
|
||||
{
|
||||
this.primary = primary;
|
||||
this.fallback = fallback;
|
||||
@ -191,8 +194,8 @@ namespace osu.Game.Rulesets.UI
|
||||
private readonly ShaderManager primary;
|
||||
private readonly ShaderManager fallback;
|
||||
|
||||
public FallbackShaderManager(ShaderManager primary, ShaderManager fallback)
|
||||
: base(new ResourceStore<byte[]>())
|
||||
public FallbackShaderManager(IRenderer renderer, ShaderManager primary, ShaderManager fallback)
|
||||
: base(renderer, new ResourceStore<byte[]>())
|
||||
{
|
||||
this.primary = primary;
|
||||
this.fallback = fallback;
|
||||
|
@ -8,7 +8,6 @@ using System.Linq;
|
||||
using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Game.Audio;
|
||||
using osu.Game.Skinning;
|
||||
|
@ -8,10 +8,10 @@ using osu.Framework.Audio;
|
||||
using osu.Framework.Audio.Track;
|
||||
using osu.Framework.Extensions.Color4Extensions;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Batches;
|
||||
using osu.Framework.Graphics.Colour;
|
||||
using osu.Framework.Graphics.OpenGL.Vertices;
|
||||
using osu.Framework.Graphics.Primitives;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Rendering.Vertices;
|
||||
using osu.Framework.Graphics.Shaders;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Utils;
|
||||
@ -71,12 +71,10 @@ namespace osu.Game.Screens.Menu
|
||||
private readonly float[] frequencyAmplitudes = new float[256];
|
||||
|
||||
private IShader shader = null!;
|
||||
|
||||
private readonly Texture texture;
|
||||
private Texture texture = null!;
|
||||
|
||||
public LogoVisualisation()
|
||||
{
|
||||
texture = Texture.WhitePixel;
|
||||
Blending = BlendingParameters.Additive;
|
||||
}
|
||||
|
||||
@ -88,8 +86,9 @@ namespace osu.Game.Screens.Menu
|
||||
}
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(ShaderManager shaders)
|
||||
private void load(IRenderer renderer, ShaderManager shaders)
|
||||
{
|
||||
texture = renderer.WhitePixel;
|
||||
shader = shaders.Load(VertexShaderDescriptor.TEXTURE_2, FragmentShaderDescriptor.TEXTURE_ROUNDED);
|
||||
}
|
||||
|
||||
@ -173,7 +172,7 @@ namespace osu.Game.Screens.Menu
|
||||
|
||||
private readonly float[] audioData = new float[256];
|
||||
|
||||
private readonly QuadBatch<TexturedVertex2D> vertexBatch = new QuadBatch<TexturedVertex2D>(100, 10);
|
||||
private IVertexBatch<TexturedVertex2D>? vertexBatch;
|
||||
|
||||
public VisualisationDrawNode(LogoVisualisation source)
|
||||
: base(source)
|
||||
@ -191,9 +190,11 @@ namespace osu.Game.Screens.Menu
|
||||
Source.frequencyAmplitudes.AsSpan().CopyTo(audioData);
|
||||
}
|
||||
|
||||
public override void Draw(Action<TexturedVertex2D> vertexAction)
|
||||
public override void Draw(IRenderer renderer)
|
||||
{
|
||||
base.Draw(vertexAction);
|
||||
base.Draw(renderer);
|
||||
|
||||
vertexBatch ??= renderer.CreateQuadBatch<TexturedVertex2D>(100, 10);
|
||||
|
||||
shader.Bind();
|
||||
|
||||
@ -228,7 +229,7 @@ namespace osu.Game.Screens.Menu
|
||||
Vector2Extensions.Transform(barPosition + bottomOffset + amplitudeOffset, DrawInfo.Matrix)
|
||||
);
|
||||
|
||||
DrawQuad(
|
||||
renderer.DrawQuad(
|
||||
texture,
|
||||
rectangle,
|
||||
colourInfo,
|
||||
@ -246,7 +247,7 @@ namespace osu.Game.Screens.Menu
|
||||
{
|
||||
base.Dispose(isDisposing);
|
||||
|
||||
vertexBatch.Dispose();
|
||||
vertexBatch?.Dispose();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -78,7 +78,7 @@ namespace osu.Game.Screens.OnlinePlay
|
||||
|
||||
private IBeatmapInfo beatmap;
|
||||
private IRulesetInfo ruleset;
|
||||
private Mod[] requiredMods;
|
||||
private Mod[] requiredMods = Array.Empty<Mod>();
|
||||
|
||||
private Container maskingContainer;
|
||||
private Container difficultyIconContainer;
|
||||
@ -139,7 +139,8 @@ namespace osu.Game.Screens.OnlinePlay
|
||||
ruleset = rulesets.GetRuleset(Item.RulesetID);
|
||||
var rulesetInstance = ruleset?.CreateInstance();
|
||||
|
||||
requiredMods = Item.RequiredMods.Select(m => m.ToMod(rulesetInstance)).ToArray();
|
||||
if (rulesetInstance != null)
|
||||
requiredMods = Item.RequiredMods.Select(m => m.ToMod(rulesetInstance)).ToArray();
|
||||
}
|
||||
|
||||
protected override void LoadComplete()
|
||||
|
@ -9,7 +9,6 @@ using JetBrains.Annotations;
|
||||
using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Game.Audio;
|
||||
@ -54,7 +53,7 @@ namespace osu.Game.Skinning
|
||||
{
|
||||
foreach (string lookup in sampleInfo.LookupNames)
|
||||
{
|
||||
var sample = Samples?.Get(lookup) ?? resources.AudioManager.Samples.Get(lookup);
|
||||
var sample = Samples?.Get(lookup) ?? resources.AudioManager?.Samples.Get(lookup);
|
||||
if (sample != null)
|
||||
return sample;
|
||||
}
|
||||
|
@ -5,7 +5,7 @@
|
||||
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.Timing;
|
||||
|
||||
namespace osu.Game.Skinning
|
||||
|
@ -4,7 +4,6 @@
|
||||
using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Game.Audio;
|
||||
|
||||
|
@ -10,7 +10,6 @@ using JetBrains.Annotations;
|
||||
using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.IO.Stores;
|
||||
using osu.Game.Audio;
|
||||
|
@ -9,7 +9,6 @@ using osu.Framework.Allocation;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Animations;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using static osu.Game.Skinning.SkinConfiguration;
|
||||
|
@ -8,7 +8,6 @@ using JetBrains.Annotations;
|
||||
using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Game.Audio;
|
||||
using osu.Game.Rulesets.Objects.Legacy;
|
||||
|
@ -6,7 +6,6 @@ using osu.Framework.Audio;
|
||||
using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.IO.Stores;
|
||||
using osu.Framework.Platform;
|
||||
@ -24,7 +23,7 @@ namespace osu.Game.Skinning
|
||||
|
||||
public ResourceStoreBackedSkin(IResourceStore<byte[]> resources, GameHost host, AudioManager audio)
|
||||
{
|
||||
textures = new TextureStore(host.CreateTextureLoaderStore(new NamespacedResourceStore<byte[]>(resources, @"Textures")));
|
||||
textures = new TextureStore(host.Renderer, host.CreateTextureLoaderStore(new NamespacedResourceStore<byte[]>(resources, @"Textures")));
|
||||
samples = audio.GetSampleStore(new NamespacedResourceStore<byte[]>(resources, @"Samples"));
|
||||
}
|
||||
|
||||
|
@ -11,7 +11,6 @@ using Newtonsoft.Json;
|
||||
using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.IO.Stores;
|
||||
using osu.Framework.Logging;
|
||||
@ -78,7 +77,7 @@ namespace osu.Game.Skinning
|
||||
(storage as ResourceStore<byte[]>)?.AddExtension("ogg");
|
||||
|
||||
Samples = samples;
|
||||
Textures = new TextureStore(resources.CreateTextureLoaderStore(storage));
|
||||
Textures = new TextureStore(resources.Renderer, resources.CreateTextureLoaderStore(storage));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -14,7 +14,7 @@ using osu.Framework.Audio;
|
||||
using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.IO.Stores;
|
||||
using osu.Framework.Platform;
|
||||
@ -249,6 +249,7 @@ namespace osu.Game.Skinning
|
||||
|
||||
#region IResourceStorageProvider
|
||||
|
||||
IRenderer IStorageResourceProvider.Renderer => host.Renderer;
|
||||
AudioManager IStorageResourceProvider.AudioManager => audio;
|
||||
IResourceStore<byte[]> IStorageResourceProvider.Resources => resources;
|
||||
IResourceStore<byte[]> IStorageResourceProvider.Files => userFiles;
|
||||
|
@ -12,7 +12,6 @@ using osu.Framework.Audio.Sample;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Game.Audio;
|
||||
|
||||
|
@ -90,7 +90,7 @@ namespace osu.Game.Storyboards.Drawables
|
||||
if (clock != null)
|
||||
Clock = clock;
|
||||
|
||||
dependencies.Cache(new TextureStore(host.CreateTextureLoaderStore(new RealmFileStore(realm, host.Storage).Store), false, scaleAdjust: 1));
|
||||
dependencies.Cache(new TextureStore(host.Renderer, host.CreateTextureLoaderStore(new RealmFileStore(realm, host.Storage).Store), false, scaleAdjust: 1));
|
||||
|
||||
foreach (var layer in Storyboard.Layers)
|
||||
{
|
||||
|
@ -12,8 +12,10 @@ using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Audio;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.IO.Stores;
|
||||
using osu.Framework.Platform;
|
||||
using osu.Framework.Testing;
|
||||
using osu.Framework.Timing;
|
||||
using osu.Game.Beatmaps;
|
||||
@ -39,6 +41,9 @@ namespace osu.Game.Tests.Beatmaps
|
||||
[Resolved]
|
||||
private RulesetStore rulesetStore { get; set; }
|
||||
|
||||
[Resolved]
|
||||
private GameHost host { get; set; }
|
||||
|
||||
private readonly SkinInfo userSkinInfo = new SkinInfo();
|
||||
|
||||
private readonly BeatmapInfo beatmapInfo = new BeatmapInfo
|
||||
@ -123,6 +128,7 @@ namespace osu.Game.Tests.Beatmaps
|
||||
|
||||
#region IResourceStorageProvider
|
||||
|
||||
public IRenderer Renderer => host.Renderer;
|
||||
public AudioManager AudioManager => Audio;
|
||||
public IResourceStore<byte[]> Files => userSkinResourceStore;
|
||||
public new IResourceStore<byte[]> Resources => base.Resources;
|
||||
@ -212,6 +218,7 @@ namespace osu.Game.Tests.Beatmaps
|
||||
|
||||
protected internal override ISkin GetSkin() => new LegacyBeatmapSkin(skinBeatmapInfo, this);
|
||||
|
||||
public IRenderer Renderer => resources.Renderer;
|
||||
public AudioManager AudioManager => resources.AudioManager;
|
||||
|
||||
public IResourceStore<byte[]> Files { get; }
|
||||
|
@ -11,7 +11,7 @@ using osu.Framework.Allocation;
|
||||
using osu.Framework.Audio;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.OpenGL.Textures;
|
||||
using osu.Framework.Graphics.Rendering;
|
||||
using osu.Framework.Graphics.Shapes;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Framework.IO.Stores;
|
||||
@ -159,6 +159,7 @@ namespace osu.Game.Tests.Visual
|
||||
|
||||
#region IResourceStorageProvider
|
||||
|
||||
public IRenderer Renderer => host.Renderer;
|
||||
public AudioManager AudioManager => Audio;
|
||||
public IResourceStore<byte[]> Files => null;
|
||||
public new IResourceStore<byte[]> Resources => base.Resources;
|
||||
|
@ -36,7 +36,7 @@
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
<PackageReference Include="Realm" Version="10.14.0" />
|
||||
<PackageReference Include="ppy.osu.Framework" Version="2022.730.0" />
|
||||
<PackageReference Include="ppy.osu.Framework" Version="2022.805.0" />
|
||||
<PackageReference Include="ppy.osu.Game.Resources" Version="2022.722.0" />
|
||||
<PackageReference Include="Sentry" Version="3.19.0" />
|
||||
<PackageReference Include="SharpCompress" Version="0.32.1" />
|
||||
|
@ -61,7 +61,7 @@
|
||||
<Reference Include="System.Net.Http" />
|
||||
</ItemGroup>
|
||||
<ItemGroup Label="Package References">
|
||||
<PackageReference Include="ppy.osu.Framework.iOS" Version="2022.730.0" />
|
||||
<PackageReference Include="ppy.osu.Framework.iOS" Version="2022.805.0" />
|
||||
<PackageReference Include="ppy.osu.Game.Resources" Version="2022.722.0" />
|
||||
</ItemGroup>
|
||||
<!-- See https://github.com/dotnet/runtime/issues/35988 (can be removed after Xamarin uses net6.0) -->
|
||||
@ -84,7 +84,7 @@
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.Sqlite" Version="5.0.14" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.Sqlite.Core" Version="5.0.14" />
|
||||
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
|
||||
<PackageReference Include="ppy.osu.Framework" Version="2022.730.0" />
|
||||
<PackageReference Include="ppy.osu.Framework" Version="2022.805.0" />
|
||||
<PackageReference Include="SharpCompress" Version="0.32.1" />
|
||||
<PackageReference Include="NUnit" Version="3.13.3" />
|
||||
<PackageReference Include="System.ComponentModel.Annotations" Version="5.0.0" />
|
||||
|
Loading…
Reference in New Issue
Block a user