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

Class ResizerVSP

source code

AbstractVSP --+
              |
             ResizerVSP

This VSP resizes each frame of video. Subsequent VSPs in a chain will see the resized image instead of the original.

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

Inherited from AbstractVSP: __call__

Method Details [hide private]

__init__(self, new_size=(320, 240), window='Resized Image', 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.
Overrides: AbstractVSP.__init__
(inherited documentation)

_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.

Overrides: AbstractVSP._onNewFrame
(inherited documentation)