Files
Ipseity-Demo/Packages/OctoCore/Runtime/Scripts/Navigation/IOctoSceneTransition.cs
T
2026-07-17 18:30:24 +02:00

37 lines
1.5 KiB
C#

using System;
using UnityEngine;
using UnityEngine.Video;
namespace OctoCore.Transitions
{
/// <summary>
/// Contract for a scene-transition visual effect (eyelid blink, plain fade, etc.).
/// Lives inside the OctoCore package and has zero dependency on any concrete
/// implementation or third-party tweening library. OctoNavigation only ever
/// talks to this interface, never to a concrete type.
/// </summary>
public interface IOctoSceneTransition
{
/// <summary>True while a transition sequence is currently animating.</summary>
bool IsBusy { get; }
/// <summary>
/// Assigns the visual content (clip/material) to use for the next CloseEyes() call.
/// Pass a null clip for a plain transition with no video overlay.
/// </summary>
void SetClip(VideoClip clip, Material material);
/// <summary>Closes the transition over the given duration and invokes the callback on completion.</summary>
void CloseEyes(float duration, Action onComplete);
/// <summary>Opens the transition over the given duration and invokes the callback on completion.</summary>
void OpenEyes(float duration, Action onComplete);
/// <summary>Stops and hides any video overlay currently playing.</summary>
void HideVideo();
/// <summary>Reveals the video overlay after the given delay, if a clip is assigned.</summary>
void ShowVideoAfterDelay(float delay);
}
}