2020-03-08 05:32:03 +00:00
|
|
|
|
// 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.Graphics;
|
|
|
|
|
using osu.Game.Storyboards.Drawables;
|
2024-04-22 10:43:15 +00:00
|
|
|
|
using osuTK;
|
2020-03-08 05:32:03 +00:00
|
|
|
|
|
|
|
|
|
namespace osu.Game.Storyboards
|
|
|
|
|
{
|
2024-04-22 10:43:15 +00:00
|
|
|
|
public class StoryboardVideo : StoryboardSprite
|
2020-03-08 05:32:03 +00:00
|
|
|
|
{
|
2023-09-11 14:59:44 +00:00
|
|
|
|
public StoryboardVideo(string path, double offset)
|
2024-04-22 10:43:15 +00:00
|
|
|
|
: base(path, Anchor.Centre, Vector2.Zero)
|
2020-03-08 05:32:03 +00:00
|
|
|
|
{
|
2024-04-23 14:03:32 +00:00
|
|
|
|
// This is just required to get a valid StartTime based on the incoming offset.
|
|
|
|
|
// Actual fades are handled inside DrawableStoryboardVideo for now.
|
2024-05-01 20:57:21 +00:00
|
|
|
|
Commands.AddAlpha(Easing.None, offset, offset, 0, 0);
|
2020-03-08 05:32:03 +00:00
|
|
|
|
}
|
|
|
|
|
|
2024-04-22 10:43:15 +00:00
|
|
|
|
public override Drawable CreateDrawable() => new DrawableStoryboardVideo(this);
|
2020-03-08 05:32:03 +00:00
|
|
|
|
}
|
|
|
|
|
}
|