## motioncells

motioncells

## Properties

gboolean | calculatemotion | Read / Write
gchar * | cellscolor | Read / Write
gchar * | datafile | Read / Write
gchar * | datafileextension | Read / Write
gboolean | display | Read / Write
gint | gap | Read / Write
gint | gridx | Read / Write
gint | gridy | Read / Write
gint | minimummotionframes | Read / Write
gchar * | motioncellsidx | Read / Write
gint | motioncellthickness | Read / Write
gchar * | motionmaskcellspos | Read / Write
gchar * | motionmaskcoords | Read / Write
gboolean | postallmotion | Read / Write
gint | postnomotion | Read / Write
gdouble | sensitivity | Read / Write
gdouble | threshold | Read / Write
gboolean | usealpha | Read / Write

## Types and Values

struct | GstMotioncells

## Object Hierarchy

        GObject
        ╰── GInitiallyUnowned
            ╰── GstObject
                ╰── GstElement
                    ╰── GstBaseTransform
                        ╰── GstVideoFilter
                            ╰── GstOpencvVideoFilter
                                ╰── GstMotioncells

## Description

Performs motion detection on videos.

### Example launch line

    1

    gst-launch-1.0 videotestsrc pattern=18 ! videorate ! videoscale ! video/x-raw,width=320,height=240,framerate=5/1 ! videoconvert ! motioncells ! videoconvert ! xvimagesink

## Synopsis

### Element Information

plugin | opencv
author | Robert Jobbagy <jobbagy dot robert at gmail dot com>, Nicola Murino <nicola dot murino at gmail.com>
class | Filter/Effect/Video

### Element Pads

name | sink
direction | sink
presence | always
details | video/x-raw, format=(string)RGB, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]

name | src
direction | source
presence | always
details | video/x-raw, format=(string)RGB, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]

## Functions

## Types and Values

### struct GstMotioncells

    struct GstMotioncells;

## Property Details

### The `“calculatemotion”` property

      “calculatemotion”          gboolean

Toggles motion calculation. If FALSE, this filter does nothing.

Flags: Read / Write

Default value: TRUE

### The `“cellscolor”` property

      “cellscolor”               gchar *

Color for motion cells in R,G,B format. Max per channel is 255.

Flags: Read / Write

Default value: "255,255,0"

### The `“datafile”` property

      “datafile”                 gchar *

Location of motioncells data file (empty string means no saving).

Flags: Read / Write

Default value: NULL

### The `“datafileextension”` property

      “datafileextension”        gchar *

Extension of datafile.

Flags: Read / Write

Default value: "vamc"

### The `“display”` property

      “display”                  gboolean

Toggle display of motion cells on current frame.

Flags: Read / Write

Default value: FALSE

### The `“gap”` property

      “gap”                      gint

Interval in seconds after which motion is considered finished and a motion finished bus message is posted.

Flags: Read / Write

Allowed values: [1,60]

Default value: 5

### The `“gridx”` property

      “gridx”                    gint

Number of horizontal grid cells.

Flags: Read / Write

Allowed values: [8,32]

Default value: 10

### The `“gridy”` property

      “gridy”                    gint

Number of vertical grid cells.

Flags: Read / Write

Allowed values: [8,32]

Default value: 10

### The `“minimummotionframes”` property

      “minimummotionframes”      gint

Minimum number of motion frames triggering a motion event.

Flags: Read / Write

Allowed values: [1,60]

Default value: 1

### The `“motioncellsidx”` property

      “motioncellsidx”           gchar *

Describe a cell with its line and column idx separated with ":". Pass multiple cells as a comma-separated list.

Flags: Read / Write

Default value: NULL

### The `“motioncellthickness”` property

      “motioncellthickness”      gint

Motion Cell Border Thickness. Set to -1 to fill motion cell.

Flags: Read / Write

Allowed values: [G_MAXULONG,5]

Default value: 1

### The `“motionmaskcellspos”` property

      “motionmaskcellspos”       gchar *

Describe a cell with its line and column idx separated with ":". Pass multiple cells as a comma-separated list.

Flags: Read / Write

Default value: NULL

### The `“motionmaskcoords”` property

      “motionmaskcoords”         gchar *

Describe a region with its upper left and lower right x, y coordinates separated with ":". Pass multiple regions as a comma-separated list.

Flags: Read / Write

Default value: NULL

### The `“postallmotion”` property

      “postallmotion”            gboolean

Post bus messages for every motion frame or just motion start and motion stop.

Flags: Read / Write

Default value: FALSE

### The `“postnomotion”` property

      “postnomotion”             gint

If non 0, post a no_motion event on the bus if no motion is detected for the given number of seconds.

Flags: Read / Write

Allowed values: [0,180]

Default value: 0

### The `“sensitivity”` property

      “sensitivity”              gdouble

Motion detection sensitivity.

Flags: Read / Write

Allowed values: [0,1]

Default value: 0.5

### The `“threshold”` property

      “threshold”                gdouble

Threshold value for motion. Filter detects motion when at least this fraction of the cells have moved.

Flags: Read / Write

Allowed values: [0,1]

Default value: 0.01

### The `“usealpha”` property

      “usealpha”                 gboolean

Toggle usage of alpha blending on frames with motion cells.

Flags: Read / Write

Default value: TRUE