using System; using UnityEngine; using UnityEngine.Video; namespace OctoCore.Transitions { /// /// 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. /// public interface IOctoSceneTransition { /// True while a transition sequence is currently animating. bool IsBusy { get; } /// /// 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. /// void SetClip(VideoClip clip, Material material); /// /// Enables or disables the eyelid/video layer swap for the next CloseEyes()/OpenEyes() /// sequence, if the implementation supports it. Implementations that don't support /// layer swapping can treat this as a no-op. /// void SetLayerSwapEnabled(bool enabled); /// Closes the transition over the given duration and invokes the callback on completion. void CloseEyes(float duration, Action onComplete); /// Opens the transition over the given duration and invokes the callback on completion. void OpenEyes(float duration, Action onComplete); /// Stops and hides any video overlay currently playing. void HideVideo(); /// Reveals the video overlay after the given delay, if a clip is assigned. void ShowVideoAfterDelay(float delay); /// /// Hides the video overlay after the given delay. Lets a caller make the video /// disappear partway through the opening animation instead of only once it has /// fully finished. /// void HideVideoAfterDelay(float delay); } }