Class (GI Struct)

GstVideo-1.0GstVideoVideoOverlayComposition

Functions to create and handle overlay compositions on video buffers.

An overlay composition describes one or more overlay rectangles to be blended on top of a video buffer.

This API serves two main purposes:

  • it can be used to attach overlay information (subtitles or logos) to non-raw video buffers such as GL/VAAPI/VDPAU surfaces. The actual blending of the overlay can then be done by e.g. the video sink that processes these non-raw buffers.

  • it can also be used to blend overlay rectangles on top of raw video buffers, thus consolidating blending functionality for raw video in one place.

Together, this allows existing overlay elements to easily handle raw and non-raw video as input in without major changes (once the overlays have been put into a GstVideo.VideoOverlayComposition object anyway) - for raw video the overlay can just use the blending function to blend the data on top of the video, and for surface buffers it can just attach them to the buffer and let the sink render the overlays.

Index

Constructors

Properties

Methods

  • Blends the overlay rectangles in comp on top of the raw video data contained in video_buf. The data in video_buf must be writable and mapped appropriately.

    Since video_buf data is read and will be modified, it ought be mapped with flag GST_MAP_READWRITE.

    Parameters

    Returns boolean

  • Returns the sequence number of this composition. Sequence numbers are monotonically increasing and unique for overlay compositions and rectangles (meaning there will never be a rectangle with the same sequence number as a composition).

    Returns number

    the sequence number of comp