Class TofArMeshManager
TofAr Meshコンポーネントとの接続を管理する
下記機能を有する
- Mesh生成パラメータの設定
- Meshデータの取得
- ストリーム開始イベント通知
- ストリーム終了イベント通知
- フレーム到着通知
- 録画ファイルの再生
Inheritance
Inherited Members
Namespace: TofAr.V0.Mesh
Assembly: TofArMeshAssembly.dll
Syntax
public class TofArMeshManager : Singleton<TofArMeshManager>, IStreamStoppable, IDisposable, IStreamHolder, IDependManager
Fields
autoStart
trueの場合、アプリケーション開始時に自動的にMeshデータのストリームを開始する
Declaration
public bool autoStart
Field Value
Type |
---|
System.Boolean |
Properties
FrameRate
実測FPS
Declaration
public float FrameRate { get; }
Property Value
Type |
---|
System.Single |
IsPlaying
trueの場合、録画ファイルを再生している
Declaration
public bool IsPlaying { get; }
Property Value
Type |
---|
System.Boolean |
IsStreamActive
trueの場合ストリーミングを行っている
Declaration
public bool IsStreamActive { get; }
Property Value
Type |
---|
System.Boolean |
MeshData
最新のMeshデータ
Declaration
public MeshData MeshData { get; }
Property Value
Type |
---|
MeshData |
MeshReductionLevel
Meshリダクションレベル
0:リダクションなし
1~:リダクション実施
デフォルト=0
Declaration
public int MeshReductionLevel { get; set; }
Property Value
Type |
---|
System.Int32 |
ResetTrianglePeriod
トライアングル計算の間隔フレーム数
デフォルト=4
Declaration
public int ResetTrianglePeriod { get; set; }
Property Value
Type |
---|
System.Int32 |
Stream
ストリーム
Declaration
public Stream Stream { get; }
Property Value
Type |
---|
SensCord.Stream |
StreamPlay
再生ストリーム
Declaration
public Stream StreamPlay { get; }
Property Value
Type |
---|
SensCord.Stream |
Version
コンポーネントのバージョン番号
Declaration
public string Version { get; }
Property Value
Type |
---|
System.String |
Methods
Dispose()
破棄時処理
Declaration
public void Dispose()
Dispose(Boolean)
破棄処理
Declaration
public void Dispose(bool ignoreEventRelease)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | ignoreEventRelease | trueの場合、イベントハンドラのクリアをスキップする |
FinalizeRestartStreamByDependManager(Object)
依存するManagerから要求されたストリーミング再スタート後処理
Declaration
public void FinalizeRestartStreamByDependManager(object requestSource)
Parameters
Type | Name | Description |
---|---|---|
System.Object | requestSource | 要求元 |
GetProperty<T>()
コンポーネントプロパティを取得する
Declaration
public T GetProperty<T>()
where T : class, IBaseProperty, new()
Returns
Type | Description |
---|---|
T | プロパティクラス |
Type Parameters
Name | Description |
---|---|
T | IBaseProperty継承クラス |
GetProperty<T>(T)
コンポーネントプロパティを取得する。入力パラメータvalueを指定可能。
Declaration
public T GetProperty<T>(T value)
where T : class, IBaseProperty
Parameters
Type | Name | Description |
---|---|---|
T | value | 入力パラメータ |
Returns
Type | Description |
---|---|
T | プロパティクラス |
Type Parameters
Name | Description |
---|---|
T | IBaseProperty継承クラス |
GetProperty<T>(T, Int32)
シリアライズ用バッファサイズを指定してコンポーネントプロパティを取得する。入力パラメータvalueを指定可能。
Declaration
public T GetProperty<T>(T value, int bufferSize)
where T : class, IBaseProperty, new()
Parameters
Type | Name | Description |
---|---|---|
T | value | 入力パラメータ |
System.Int32 | bufferSize | シリアライズ用バッファサイズ |
Returns
Type | Description |
---|---|
T | プロパティクラス |
Type Parameters
Name | Description |
---|---|
T | IBaseProperty継承クラス |
GetPropertyList()
Propertyリストを取得する
Declaration
public string[] GetPropertyList()
Returns
Type | Description |
---|---|
System.String[] | Propertyリスト |
RegisterMeshPreProcessing(IPreProcessMeshData)
Meshデータ送出前の処理を登録する
Declaration
public void RegisterMeshPreProcessing(IPreProcessMeshData preProcessMesh)
Parameters
Type | Name | Description |
---|---|---|
IPreProcessMeshData | preProcessMesh | Meshデータ処理クラス |
RestartStreamByDependManager(Object)
依存するManagerから要求されたストリーミング再スタートを開始する
Declaration
public void RestartStreamByDependManager(object requestSource)
Parameters
Type | Name | Description |
---|---|---|
System.Object | requestSource | 要求元 |
SetProperty<T>(T)
コンポーネントプロパティを設定する
Declaration
public void SetProperty<T>(T value)
where T : class, IBaseProperty
Parameters
Type | Name | Description |
---|---|---|
T | value | 入力パラメータ |
Type Parameters
Name | Description |
---|---|
T | IBaseProperty継承クラス |
StartPlayback()
録画ファイル再生中のToFストリームをソースとして再生を開始する
Declaration
public void StartPlayback()
StartPlayback(String)
指定されたパス内の録画ファイルの再生を開始する
Declaration
public void StartPlayback(string path)
Parameters
Type | Name | Description |
---|---|---|
System.String | path | 再生する録画ファイルを含むディレクトリのパス |
StartStream()
ストリーミングを開始する
Declaration
public void StartStream()
StartStream(AlgorithmConfigProperty)
ストリーミングを開始する
Declaration
public void StartStream(AlgorithmConfigProperty configuration)
Parameters
Type | Name | Description |
---|---|---|
AlgorithmConfigProperty | configuration | ストリーミングに使用するMesh生成パラメータ |
StopPlayback()
録画ファイルの再生を停止する
Declaration
public void StopPlayback()
StopStream(Object)
ストリーミングを停止する
Declaration
public void StopStream(object sender = null)
Parameters
Type | Name | Description |
---|---|---|
System.Object | sender | 送信元オブジェクト |
UnregisterMeshPreProcessing(IPreProcessMeshData)
Meshデータ送出前の処理を登録解除する
Declaration
public void UnregisterMeshPreProcessing(IPreProcessMeshData preProcessMesh)
Parameters
Type | Name | Description |
---|---|---|
IPreProcessMeshData | preProcessMesh | Meshデータ処理クラス |
Events
OnApplicationPausing
アプリケーション一時停止開始時
Declaration
public static event TofArMeshManager.ApplicationPausingEventHandler OnApplicationPausing
Event Type
Type | Description |
---|---|
TofArMeshManager.ApplicationPausingEventHandler |
OnApplicationResuming
アプリケーション復帰開始時
Declaration
public static event TofArMeshManager.ApplicationResumingEventHandler OnApplicationResuming
Event Type
Type | Description |
---|---|
TofArMeshManager.ApplicationResumingEventHandler |
OnFrameArrived
新しいフレームの到着通知
Declaration
public static event TofArMeshManager.FrameArrivedEventHandler OnFrameArrived
Event Type
Type | Description |
---|---|
TofArMeshManager.FrameArrivedEventHandler |
OnStreamStarted
ストリーミング開始通知
Declaration
public static event TofArMeshManager.StreamStartedEventHandler OnStreamStarted
Event Type
Type | Description |
---|---|
TofArMeshManager.StreamStartedEventHandler |
OnStreamStopped
ストリーミング終了通知
Declaration
public static event TofArMeshManager.StreamStoppedEventHandler OnStreamStopped
Event Type
Type | Description |
---|---|
TofArMeshManager.StreamStoppedEventHandler |