Skip to content

timosaic

abhaychirania2411 edited this page Jun 1, 2023 · 2 revisions

TI Mosaic

timosaic is used to display multiple input frames in a mosaic pattern using ARM NEON optimized scaler kernels.

Hierarchy

GObject
 +----GInitiallyUnowned
       +----GstObject
             +----GstElement
                   +----GstAggregator
                         +----GstTIMosaic

Pad templates

src

      video/x-raw
                 format: { (string)NV12 }
                 width: [ 1, 8192 ]
                 height: [ 1, 8192 ]
                 framerate: [ 0/1, 2147483647/1 ]

Availability – always

Direction – src

Object type – GstTIMosaicPad

Pad properties:

  • emit-signals: Send signals to signal data consumption

    flags: readable, writable

     Boolean.

     Default: false

  • pool-size: Pool size of the internal buffer pool

    flags: readable, writable, controllable

     Integer.

     Range: 2 - 16

     Default: 2

  • repeat-after-eos: Flag to indicate if the pad will repeat the last buffer after an EOS is received. Only valid for sink pads

    flags: readable, writable, controllable

     Boolean.

     Default: true

sink_%u

Capabilities:

      video/x-raw
                 format: { (string)NV12 }
                 width: [ 1, 8192 ]
                 height: [ 1, 8192 ]
                 framerate: [ 0/1, 2147483647/1 ]

Availability – On Request

Direction – sink

Object type – GstTIMosaicPad

Pad Properties

  • emit-signals: Send signals to signal data consumption

    flags: readable, writable

     Boolean.

     Default: false

  • height: Height of the window in output for given sink pad

     Flags : Read / Write

     Unsigned Integer

     Default value : Input height

  • pool-size: Pool size of the internal buffer pool

     Flags : Read / Write / Controllable

     Integer. Range: 2 - 16

     Default value : 2

  • startx: Starting X coordinate of the window in output for given sink pad

     Flags : Read / Write

     Unsigned Integer

     Default value : 0

  • starty: Starting Y coordinate of the window in output for given sink pad

     Flags : Read / Write

     GstValueArray of GValues of type "gint"

     Default value : 0

  • width: Width of the window in output for given sink pad

     Flags : Read / Write

     Unsigned Integer

     Default value : Input width

Properties

background

Background image of the Mosaic to be used by this element. It accepts a RAW generated file you can pass through this property. Note: When passing the background image through pad and through property at the same time, the pad one will overlap.

Flags : readable, writable, changeable only in NULL or READY state

String

Default value : ""

latency

Additional latency in live mode to allow upstream to take longer to produce buffers for the current position (in nanoseconds)

Flags : Read / Write

Unsigned Integer64. Range: 2 - 18446744073709551615

Default value : 0

min-upstream-latency

When sources with a higher latency are expected to be plugged in dynamically after the aggregator has started playing, this allows overriding the minimum latency reported by the initial source(s). This is only taken into account when larger than the actually reported minimum latency. (nanoseconds).

Flags : Read / Write

Unsigned Integer64. Range: 2 - 18446744073709551615

Default value : 0

name

The name of the object

Flags : Read / Write

String

Default value : "timosaic0"

parent

The parent of the object

Flags : Read / Write

GstObject

Default value : N/A

start-time

Start time to use if start-time-selection=set

Flags : Read / Write

Unsigned Integer64. Range: 2 - 18446744073709551615

Default value : 18446744073709551615

start-time-selection

Decides which start time is output

Flags : Read / Write

Enum

Default value : 0 ("zero")

Enum "GstAggregatorStartTimeSelection

(0): zero - Start at 0 running time (default)

(1): first - Start at first observed input running time

(2): set - Set start time with start-time property

Pipeline examples

Single input

gst-launch-1.0 \
videotestsrc num-buffers=10 pattern=ball ! video/x-raw,format=NV12 ! \
timosaic sink_0::startx=0,sink_0::starty=0,sink_0::width=1280,sink_0::height=720 ! \
video/x-raw,width=1920,height=1280 ! filesink location=mosaic_out_nv12_1_input.yuv -e -v

Multiple inputs

gst-launch-1.0                                                                                                      \
videotestsrc num-buffers=10 pattern=ball ! video/x-raw,format=NV12, width=640, height=480 ! queue ! mosaic.sink_0   \
videotestsrc num-buffers=10 pattern=ball ! video/x-raw,format=NV12, width=640, height=480 ! queue ! mosaic.sink_1   \
videotestsrc num-buffers=10 pattern=ball ! video/x-raw,format=NV12, width=640, height=480 ! queue ! mosaic.sink_2   \
videotestsrc num-buffers=10 pattern=ball ! video/x-raw,format=NV12, width=640, height=480 ! queue ! mosaic.sink_3   \
timosaic name=mosaic                                                                                                \
sink_0::startx=0 sink_0::starty=0                                                                                   \
sink_1::startx=640 sink_1::starty=480                                                                               \
sink_2::startx=0 sink_2::starty=480                                                                                 \
sink_3::startx=640 sink_3::starty=0 !                                                                               \
filesink location=mosaic_out_nv12_4_input.yuv -e -v