C# Class ARGUIController, project-tango-poc

GUI controller controls all the debug overlay to show the data for poses.
Inheritance: MonoBehaviour, ITangoLifecycle, ITangoDepth
ファイルを表示 Open project: stetro/project-tango-poc

Public Properties

Property Type Description
m_canvas Canvas
m_pointCloud TangoPointCloud,
m_prefabMarker GameObject
m_prefabTouchEffect UnityEngine.RectTransform

Public Methods

Method Description
OnGUI ( ) : void

Display simple GUI.

OnTangoDepthAvailable ( TangoUnityDepth tangoDepth ) : void

This is called each time new depth data is available. On the Tango tablet, the depth callback occurs at 5 Hz.

OnTangoPermissions ( bool permissionsGranted ) : void

This is called when the permission granting process is finished.

OnTangoServiceConnected ( ) : void

This is called when succesfully connected to the Tango service.

OnTangoServiceDisconnected ( ) : void

This is called when disconnected from the Tango service.

Start ( ) : void

Unity Start() callback, we set up some initial values here.

Update ( ) : void

Updates UI and handles player input.

Private Methods

Method Description
WorldBoundsToScreen ( Camera cam, Bounds bounds ) : Rect

Convert a 3D bounding box into a 2D Rect.

_GetLogginStringFromFrameDeltaTime ( float frameDeltaTime ) : string

Return a string to get logging of FrameDeltaTime.

_GetLoggingStringFromFrameCount ( int frameCount ) : string

Return a string to the get logging from frame count.

_GetLoggingStringFromPoseStatus ( TangoEnums status ) : string

Construct readable string from TangoPoseStatusType.

_GetLoggingStringFromQuaternion ( Quaternion quat ) : string

Reformat string from quaternion type for data logging.

_GetLoggingStringFromVec3 ( Vector3 vec ) : string

Reformat string from vector3 type for data logging.

_UpdateLocationMarker ( ) : void

Update location marker state.

_WaitForDepthAndFindPlane ( Vector2 touchPosition ) : IEnumerator

Wait for the next depth update, then find the plane at the touch position.

Method Details

OnGUI() public method

Display simple GUI.
public OnGUI ( ) : void
return void

OnTangoDepthAvailable() public method

This is called each time new depth data is available. On the Tango tablet, the depth callback occurs at 5 Hz.
public OnTangoDepthAvailable ( TangoUnityDepth tangoDepth ) : void
tangoDepth Tango.TangoUnityDepth Tango depth.
return void

OnTangoPermissions() public method

This is called when the permission granting process is finished.
public OnTangoPermissions ( bool permissionsGranted ) : void
permissionsGranted bool true if permissions were granted, otherwise false.
return void

OnTangoServiceConnected() public method

This is called when succesfully connected to the Tango service.
public OnTangoServiceConnected ( ) : void
return void

OnTangoServiceDisconnected() public method

This is called when disconnected from the Tango service.
public OnTangoServiceDisconnected ( ) : void
return void

Start() public method

Unity Start() callback, we set up some initial values here.
public Start ( ) : void
return void

Update() public method

Updates UI and handles player input.
public Update ( ) : void
return void

Property Details

m_canvas public_oe property

The canvas to place 2D game objects under.
public Canvas m_canvas
return Canvas

m_pointCloud public_oe property

The point cloud object in the scene.
public TangoPointCloud, m_pointCloud
return TangoPointCloud,

m_prefabMarker public_oe property

The marker prefab to place on taps.
public GameObject m_prefabMarker
return GameObject

m_prefabTouchEffect public_oe property

The touch effect to place on taps.
public RectTransform,UnityEngine m_prefabTouchEffect
return UnityEngine.RectTransform