Observer interface for an observable PvPipeline object. More...
Public Member Functions | |
PvPipelineEventSink () | |
PvPipeline event sink constructor. | |
virtual | ~PvPipelineEventSink () |
PvPipeline event sink destructor. | |
virtual void | OnBufferCreated (PvPipeline *aPipeline, PvBuffer *aBuffer) |
Called whenever a PvBuffer is allocated by the pipeline. More... | |
virtual void | OnBufferDeleted (PvPipeline *aPipeline, PvBuffer *aBuffer) |
Called whenever a PvBuffer is deleted by the pipeline. More... | |
virtual void | OnStart (PvPipeline *aPipeline) |
PvPipeline event sink OnStart event. More... | |
virtual void | OnStop (PvPipeline *aPipeline) |
PvPipeline event sink OnStop event. More... | |
virtual void | OnReset (PvPipeline *aPipeline) |
PvPipeline event sink OnReset event. More... | |
virtual void | OnBufferTooSmall (PvPipeline *aPipeline, bool *aReallocAll, bool *aResetStats) |
PvPipeline event sink OnBufferTooSmall event. More... | |
virtual void | OnBufferReady (PvPipeline *aPipeline) |
PvPipeline event sink OnBufferReady event. More... | |
Observer interface for an observable PvPipeline object.
PvPipelineEventSink defines a set of callback methods from a PvPIpeline object to any object implementing this interface.
To receive PvPipeline notifications:
|
virtual |
Called whenever a PvBuffer is allocated by the pipeline.
Can be used to track memory usage or structures used to follow PvBuffer pipeline management.
This method is invoked right after the PvBuffer has been created but before its payload has been allocated.
[in] | aPipeline | A pointer to the PvPipeline object. |
[in] | aBuffer | Pointer to the buffer that was just created. |
|
virtual |
Called whenever a PvBuffer is deleted by the pipeline.
Can be used to track memory usage or structures used to follow PvBuffer pipeline management.
This method is invoked right before the PvBuffer is deleted.
[in] | aPipeline | A pointer to the PvPipeline object. |
[in] | aBuffer | Pointer to the buffer that was just deleted. |
|
virtual |
PvPipeline event sink OnBufferReady event.
Invoked after a buffer has been retrieved from stream and is ready for retrieve
[in] | aPipeline | A pointer to the PvPipeline object. |
|
virtual |
PvPipeline event sink OnBufferTooSmall event.
Invoked when the pipeline retrieve a buffer from the stream object which failed with an operation result set to BUFFER_TOO_SMALL.
The user can set aRealloc all to true in order to force a complete re-allocation of the buffers performed synchronously after the notification is invoked.
If OnBufferTooSmall is not handled to aReallocAll is set to false, the buffer is re-allocated before being queued in the stream object but the other buffers are not affected until they too will fail on BUFFER_TOO_SMALL.
The aResetStats parameter is only considered if aReallocAll is set to true. The statistics do not need to be reset if the buffers are not re-allocated.
This callback is invoked from the pipeline thread.
[in] | aPipeline | A pointer to the PvPipeline object. |
[in] | aReallocAll | If set to true by at least one of the sinks, synchronous buffer re-allocation will be performed. |
[in] | aResetStats | If set to true by at least one of the sinks, stream statistics are reset. |
|
virtual |
PvPipeline event sink OnReset event.
Invoked after the pipeline has been reset.
This callback is invoked from the same thread that called PvPipeline::Reset.
[in] | aPipeline | A pointer to the PvPipeline object. |
|
virtual |
PvPipeline event sink OnStart event.
Invoked when the pipeline just before the pipeline starts.
This callback is invoked from the same thread that called PvPipeline::Start.
[in] | aPipeline | A pointer to the PvPipeline object. |
|
virtual |
PvPipeline event sink OnStop event.
Invoked right after the pipeline has been stopped.
This callback is invoked from the same thread that called PvPipeline::Stop.
[in] | aPipeline | A pointer to the PvPipeline object. |
Copyright (c) 2002-2021 Pleora Technologies Inc.
www.pleora.com