Class PanZoomBaseTexture
This script allows to zoom into and pan the texture of a GameObject. It also allows for scrolling by restricting panning to one direction.
Implements
IMixedRealityPointerHandler
IMixedRealityFocusHandler
IMixedRealitySourceStateHandler
IMixedRealityHandJointHandler
MonoBehaviour
Inherited Members
Namespace: Microsoft.MixedReality.Toolkit.Examples.Demos.EyeTracking
Assembly: cs.temp.dll.dll
Syntax
public class PanZoomBaseTexture : PanZoomBase, IMixedRealityPointerHandler, IMixedRealityFocusHandler, IMixedRealitySourceStateHandler, IMixedRealityHandJointHandler, MonoBehaviour
Fields
textureRenderer
Declaration
protected Renderer textureRenderer
Field Value
Type | Description |
---|---|
Renderer |
textureRenderer
Declaration
protected Renderer textureRenderer
Field Value
Type | Description |
---|---|
Renderer |
Properties
TextureShaderProperty
Declaration
public string TextureShaderProperty { get; set; }
Property Value
Type | Description |
---|---|
String |
TextureShaderProperty
Declaration
public string TextureShaderProperty { get; set; }
Property Value
Type | Description |
---|---|
String |
Methods
ComputePanSpeed(Single, Single, Single)
Returns the pan speed.
Declaration
public override float ComputePanSpeed(float uvCursorPos, float maxSpeed, float minDistFromCenterForAutoPan)
Parameters
Type | Name | Description |
---|---|---|
Single | uvCursorPos | |
Single | maxSpeed | |
Single | minDistFromCenterForAutoPan |
Returns
Type | Description |
---|---|
Single |
Overrides
ComputePanSpeed(Single, Single, Single)
Returns the pan speed.
Declaration
public override float ComputePanSpeed(float uvCursorPos, float maxSpeed, float minDistFromCenterForAutoPan)
Parameters
Type | Name | Description |
---|---|---|
Single | uvCursorPos | |
Single | maxSpeed | |
Single | minDistFromCenterForAutoPan |
Returns
Type | Description |
---|---|
Single |
Overrides
Initialize()
Declaration
public override void Initialize()
Overrides
Initialize()
Declaration
public override void Initialize()
Overrides
Initialize(Single)
Declaration
public void Initialize(float newAspectRatio)
Parameters
Type | Name | Description |
---|---|---|
Single | newAspectRatio |
Initialize(Single)
Declaration
public void Initialize(float newAspectRatio)
Parameters
Type | Name | Description |
---|---|---|
Single | newAspectRatio |
UpdateCursorPosInHitBox()
Determine the position of the cursor within the texture in UV space.
Declaration
public override bool UpdateCursorPosInHitBox()
Returns
Type | Description |
---|---|
Boolean | True if this GameObject is hit. |
Overrides
UpdateCursorPosInHitBox()
Determine the position of the cursor within the texture in UV space.
Declaration
public override bool UpdateCursorPosInHitBox()
Returns
Type | Description |
---|---|
Boolean | True if this GameObject is hit. |
Overrides
UpdatePanZoom()
Declaration
public override void UpdatePanZoom()
Overrides
UpdatePanZoom()
Declaration
public override void UpdatePanZoom()
Overrides
ZoomDir(Boolean)
Declaration
public override int ZoomDir(bool zoomIn)
Parameters
Type | Name | Description |
---|---|---|
Boolean | zoomIn |
Returns
Type | Description |
---|---|
Int32 |
Overrides
ZoomDir(Boolean)
Declaration
public override int ZoomDir(bool zoomIn)
Parameters
Type | Name | Description |
---|---|---|
Boolean | zoomIn |
Returns
Type | Description |
---|---|
Int32 |
Overrides
ZoomIn()
Declaration
public override void ZoomIn()
Overrides
ZoomIn()
Declaration
public override void ZoomIn()
Overrides
ZoomOut()
Declaration
public override void ZoomOut()
Overrides
ZoomOut()
Declaration
public override void ZoomOut()
Overrides
Implements
IMixedRealityPointerHandler
IMixedRealityFocusHandler
IMixedRealitySourceStateHandler
IMixedRealityHandJointHandler
MonoBehaviour