Package pyvision :: Package surveillance :: Module VideoStreamProcessor :: Class AbstractVSP
[hide private]
[frames] | no frames]

Class AbstractVSP

source code

Known Subclasses:

AbstractVSP is the abstract class definition of a Video Stream Processor (VSP) object. VSP's are designed to be chained together to accomplish processing on a video stream.

Instance Methods [hide private]
 
__init__(self, window=None, nextModule=None)
Constructor
source code
 
__call__(self, img, fn, **kwargs) source code
 
_onNewFrame(self, img, fn, **kwargs)
Override this abstract method with the processing your object performs on a per-frame basis.
source code
Method Details [hide private]

__init__(self, window=None, nextModule=None)
(Constructor)

source code 

Constructor

Parameters:
  • window - The window name to use when displaying this VSP's output. Specify None to suppress showing the output, but note that if you modify the current image with annotations, those will be persisted "downstream" to later processors.
  • nextModule - A Video Stream Processor object that should be invoked on every frame after this processor has finished.

_onNewFrame(self, img, fn, **kwargs)

source code 

Override this abstract method with the processing your object performs on a per-frame basis. It is recommended that you do not directly call this method. Rather, the VSP is a callable object, and so the __call__ method takes care of invoking this method as well as calling the next module, if any.