Class SyncProvider
A base class that includes functionality suitable for most ISyncProvider implementations.
Implements
Namespace: Unity.LiveCapture
Assembly: Unity.LiveCapture.dll
Syntax
[Serializable]
public abstract class SyncProvider : ISyncProvider
Properties
DroppedFrameCount
The number of synchronization signal pulses that have been skipped since starting the synchronization provider.
Declaration
public int DroppedFrameCount { get; }
Property Value
| Type | Description |
|---|---|
| int |
LastPulseCountDelta
The number of synchronization signal pulses between the last two WaitForNextPulse() calls.
Declaration
public int? LastPulseCountDelta { get; }
Property Value
| Type | Description |
|---|---|
| int? |
Name
The display name of the synchronization provider.
Declaration
public abstract string Name { get; }
Property Value
| Type | Description |
|---|---|
| string |
RunInEditMode
Determines if this synchronization provider can synchronize while the Editor is in edit mode.
Declaration
protected virtual bool RunInEditMode { get; }
Property Value
| Type | Description |
|---|---|
| bool |
Status
The status of the synchronization provider.
Declaration
public SyncStatus Status { get; protected set; }
Property Value
| Type | Description |
|---|---|
| SyncStatus |
SyncRate
The pulse rate of the synchronization signal.
Declaration
public virtual FrameRate SyncRate { get; }
Property Value
| Type | Description |
|---|---|
| FrameRate |
Methods
OnStart()
Called when the sync provider becomes active.
Declaration
protected virtual void OnStart()
OnStop()
Called when the sync provider becomes inactive.
Declaration
protected virtual void OnStop()
OnWaitForNextPulse(out int)
Blocks execution on the current thread until the next synchronization signal pulse is received.
Declaration
protected abstract bool OnWaitForNextPulse(out int pulseCount)
Parameters
| Type | Name | Description |
|---|---|---|
| int | pulseCount | The number of synchronization signal pulses since this method was last called. |
Returns
| Type | Description |
|---|---|
| bool | true when a pulse was successfully received; otherwise, false. |