Overlay plugin

This plugin is used to visualize objects detected in the video with bounding boxes. It is able to track them. See the metadata section for spatial informations representation in our generic format. This plugin is still in beta version. The synchronization between the objects and the bounding boxes may have some latency. We are working on it to improve the display.

These are the specific options for configuring plugin behavior:

Options Type Description
metadataId String Metadata block id to bind to
style String configures style with the following attributes: fill, strokeWidth, stroke, fillOpacity and strokeDasharray. You may look at the Raphaël library documentation for further explanations.
editable String Enable edit mode. Default value: false
defaultSelectedShape String Set default seletected shape in edit. Default value: rectangle
lineDisplayMode String Line display mode:
- STATIC : use for line configuration with parameters.
- DYNAMIC : use for line configuration with dynamic binding data type (see metadata data type).
- STATIC_DYNAMIC : use for line configuration with parameters and binding with data type.

Example

$("#myplayer-overlay").mediaPlayer({
    src : "samples-data/examples/vid/amalia01.mp4",
    plugins : {
        dataServices : [
            'samples-data/examples/json/amalia01-overlay.json'
        ],
        list : [
            {
                'className' : 'fr.ina.amalia.player.plugins.OverlayPlugin',
                'metadataId' : 'tracks-amalia01-1',
                'parameters' : {
                    style : {
                        'fill' : '#000',
                        'strokeWidth' : 1,
                        'stroke' : '#000',
                        'fillOpacity' : 0,
                        'strokeDasharray' : '- '
                    }
                }
            }
        ]
    }
});
        

Documentation