編輯

共用方式為


SceneTransitionService Class

Definition

public ref class SceneTransitionService : Microsoft::MixedReality::Toolkit::BaseExtensionService, IDisposable, Microsoft::MixedReality::Toolkit::Extensions::SceneTransitions::ISceneTransitionService
[Microsoft.MixedReality.Toolkit.MixedRealityExtensionService(Microsoft.MixedReality.Toolkit.Utilities.SupportedPlatforms.LinuxStandalone | Microsoft.MixedReality.Toolkit.Utilities.SupportedPlatforms.MacStandalone | Microsoft.MixedReality.Toolkit.Utilities.SupportedPlatforms.WindowsStandalone | Microsoft.MixedReality.Toolkit.Utilities.SupportedPlatforms.WindowsUniversal, "Scene Transition Service", "SceneTransitionService/Profiles/DefaultSceneTransitionServiceProfile.asset", "MixedRealityToolkit.Extensions", true)]
[UnityEngine.HelpURL("https://docs.microsoft.com/windows/mixed-reality/mrtk-unity/features/extensions/scene-transition-service")]
public class SceneTransitionService : Microsoft.MixedReality.Toolkit.BaseExtensionService, IDisposable, Microsoft.MixedReality.Toolkit.Extensions.SceneTransitions.ISceneTransitionService
[<Microsoft.MixedReality.Toolkit.MixedRealityExtensionService(Microsoft.MixedReality.Toolkit.Utilities.SupportedPlatforms.LinuxStandalone | Microsoft.MixedReality.Toolkit.Utilities.SupportedPlatforms.MacStandalone | Microsoft.MixedReality.Toolkit.Utilities.SupportedPlatforms.WindowsStandalone | Microsoft.MixedReality.Toolkit.Utilities.SupportedPlatforms.WindowsUniversal, "Scene Transition Service", "SceneTransitionService/Profiles/DefaultSceneTransitionServiceProfile.asset", "MixedRealityToolkit.Extensions", true)>]
[<UnityEngine.HelpURL("https://docs.microsoft.com/windows/mixed-reality/mrtk-unity/features/extensions/scene-transition-service")>]
type SceneTransitionService = class
    inherit BaseExtensionService
    interface ISceneTransitionService
    interface IMixedRealityExtensionService
    interface IMixedRealityService
    interface IDisposable
Public Class SceneTransitionService
Inherits BaseExtensionService
Implements IDisposable, ISceneTransitionService
Inheritance
SceneTransitionService
Attributes
MixedRealityExtensionServiceAttribute UnityEngine.HelpURLAttribute
Implements

Constructors

SceneTransitionService(IMixedRealityServiceRegistrar, String, UInt32, BaseMixedRealityProfile)
Obsolete.

Constructor.

SceneTransitionService(String, UInt32, BaseMixedRealityProfile)

Constructor.

Fields

DefaultPriority (Inherited from BaseService)
disposed

Value indicating if the object has completed disposal.

(Inherited from BaseService)

Properties

ConfigurationProfile

The configuration profile for the service.

(Inherited from BaseService)
FadeColor

The color to use when fading out.

FadeInTime

The default time in seconds for fade in to complete.

FadeOutTime

The default time in seconds for fade out to complete.

FadeTargets

Which cameras to target when fading.

IsEnabled

Indicates whether or not the service is currently enabled.

(Inherited from BaseService)
IsInitialized

Indicates whether or not the service has been initialized.

(Inherited from BaseService)
IsMarkedDestroyed

Indicates whether or not the Destroy method been called on this service.

(Inherited from BaseService)
Name

Optional Priority attribute if multiple services of the same type are required, enables targeting a service for action.

(Inherited from BaseService)
OnTransitionCompleted

Called when transition ends. This is called at the end of a transition, not at the end of a scene load. For scene load events, we recommend using IMixedRealitySceneSystem.

OnTransitionStarted

Called when transition starts. This is called at the beginning of a transition, not at the beginning of a scene load. For scene load events, we recommend using IMixedRealitySceneSystem.

Priority

Optional Priority to reorder registered managers based on their respective priority, reduces the risk of race conditions by prioritizing the order in which managers are evaluated.

(Inherited from BaseService)
Registrar
Obsolete.

The service registrar instance that registered this service.

(Inherited from BaseExtensionService)
TransitionInProgress

True when a scene transition is in progress.

TransitionProgress

From 0 to 1

UseFadeColor

Whether to use a fade color during transitions.

Methods

Destroy()

Optional Destroy function to perform cleanup of the service before the Mixed Reality Toolkit is destroyed.

Disable()

Optional Disable function to pause the service.

(Inherited from BaseService)
Dispose()

Cleanup resources used by this object.

(Inherited from BaseService)
Dispose(Boolean)

Cleanup resources used by the object

(Inherited from BaseService)
DoSceneTransition(Func<Task>, Func<Task>, IProgressIndicator)

Fades out, enables progress indicator, executes scene op 1, executes scene op 2, disables progress indicator, fades back in

DoSceneTransition(Func<Task>, IProgressIndicator)

Fades out, enables progress indicator, execute scene operation, disables progress indicator, fades back in

DoSceneTransition(IEnumerable<Func<Task>>, IProgressIndicator)

Fades out, enables progress indicator, execute scene operations in order, disables progress indicator, fades back in

DoSceneTransition(IEnumerable<Func<Task>>, Single, Single, IProgressIndicator)

Fades out, enables progress indicator, execute scene operations in order, disables progress indicator, fades back in

Enable()

Optional Enable function to enable / re-enable the service.

FadeIn()

Fades target cameras in. Instant fade-out will occur if fade state is not opaque. Can be used independently of scene transitions provided no transition is taking place. Uses default FadeInTime.

FadeIn(Single)

Fades target cameras in. Instant fade-out will occur if fade state is not opaque. Can be used independently of scene transitions provided no transition is taking place.

FadeOut()

Fades target cameras out to color. Can be used independently of scene transitions provided no transition is taking place. Uses default FadeOutTime.

FadeOut(Single)

Fades target cameras out to color. Can be used independently of scene transitions provided no transition is taking place.

HideProgressIndicator()

Hides the default progress indicator. Task completes when hide animation is done. Can be used independently of scene transitions provided no transition is taking place.

Initialize()

The initialize function is used to setup the service once created. This method is called once all services have been registered in the Mixed Reality Toolkit.

LateUpdate()

Optional LateUpdate function to that is called after Update has been called on all services.

(Inherited from BaseService)
Reset()

Optional Reset function to perform that will Reset the service, for example, whenever there is a profile change.

(Inherited from BaseService)
SetCustomFadeTargetCameras(IEnumerable<Camera>)

If FadeTargets is set to custom, you will need to provide a custom set of cameras for fading using this function PRIOR to calling DoSceneTransition.

SetProgressMessage(String)

Sets the message on displayed progress indicator. If no progress indicator exists, has no effect.

SetProgressValue(Single)

Sets progress to value from 0-1. If no progress indicator exists, has no effect.

ShowDefaultProgressIndicator()

Instantiates the default progress indicator and returns its main transform. Can be used independently of scene transitions provided no transition is taking place.

Update()

Optional Update function to perform per-frame updates of the service.

(Inherited from BaseService)

Applies to