Generic video plugin
VideoPlugin can be attached to SceneRenderer instances. Usually they perform simple image transformations on video stream, e.g. smooth effects or gamma correction. VideoPlugin interface is very similar to Renderer and consist of two basic methods load() and update(). But instead of a scene, update() works with input image provided within canvas element. Plugin is a level of abstraction to single out ready-made helpers that can be reused as atomic building blocks of the application.
|extends ||Type of processing results|
• new VideoPlugin<
Dispose render plugin
Initializes everything required for image processing. Overridden by derived classes for particular filter.
Promise resolving when initialization is finished
Releases all resources and instances created in load(). Overridden by derived classes for particular filter.
Update the image
Main method implementing image filter or 2D drawing. Updates the image according to provided results. Image is updated in place drawing on canvas directly. Overridden by derived classes for particular filter.
|Results of video processing|
|Captured video frame|
|Rendering context of canvas|
Promise resolving when update is finished