Class InteractableRotationTheme
Theme Engine to control a GameObject's rotation based on state changes
Inherited Members
Namespace: Microsoft.MixedReality.Toolkit.UI
Assembly: cs.temp.dll.dll
Syntax
public class InteractableRotationTheme : InteractableThemeBase
Constructors
InteractableRotationTheme()
Declaration
public InteractableRotationTheme()
Fields
hostTransform
Declaration
protected Transform hostTransform
Field Value
Type | Description |
---|---|
Transform |
originalLocalRotation
Declaration
protected Vector3 originalLocalRotation
Field Value
Type | Description |
---|---|
Vector3 |
originalRotation
Declaration
protected Vector3 originalRotation
Field Value
Type | Description |
---|---|
Vector3 |
Properties
IsLocalRotation
If true, the theme manipulate the target's local rotation. Otherwise, the theme will control the world space rotation.
Declaration
public bool IsLocalRotation { get; }
Property Value
Type | Description |
---|---|
Boolean |
IsRelativeRotation
If true, the theme rotation value will be added to the initial Gameobject's rotation. Otherwise, it will set directly as absolute euler angles.
Declaration
public bool IsRelativeRotation { get; }
Property Value
Type | Description |
---|---|
Boolean |
Methods
GetDefaultThemeDefinition()
Generates the default theme definition configuration for the current theme implementation
Declaration
public override ThemeDefinition GetDefaultThemeDefinition()
Returns
Type | Description |
---|---|
ThemeDefinition | Default ThemeDefinition to initialize with the current theme engine implementation |
Overrides
GetProperty(ThemeStateProperty)
Get the current property value for the provided state property
Declaration
public override ThemePropertyValue GetProperty(ThemeStateProperty property)
Parameters
Type | Name | Description |
---|---|---|
ThemeStateProperty | property | state property to access |
Returns
Type | Description |
---|---|
ThemePropertyValue | Value currently for given state property |
Overrides
Init(GameObject, ThemeDefinition)
Initialize current Theme Engine with given configuration and target the provided GameObject
Declaration
public override void Init(GameObject host, ThemeDefinition settings)
Parameters
Type | Name | Description |
---|---|---|
GameObject | host | GameObject to target changes against |
ThemeDefinition | settings |
Overrides
Reset()
Resets properties on Host GameObject to their original values when Init() was called for this theme engine. Useful for reverting changes done by this theme engine.
Declaration
public override void Reset()
Overrides
SetValue(ThemeStateProperty, ThemePropertyValue)
Instruct theme to set value for current property with ThemePropertyValue value provided
Declaration
protected override void SetValue(ThemeStateProperty property, ThemePropertyValue value)
Parameters
Type | Name | Description |
---|---|---|
ThemeStateProperty | property | property to update value |
ThemePropertyValue | value | Value for theme to set |
Overrides
SetValue(ThemeStateProperty, Int32, Single)
Instruct theme to set value for current property with given index state and at given lerp percentage
Declaration
public override void SetValue(ThemeStateProperty property, int index, float percentage)
Parameters
Type | Name | Description |
---|---|---|
ThemeStateProperty | property | property to update value |
Int32 | index | index of state to access array of values |
Single | percentage | percentage transition between values |