GstBaseParseClass

Subclasses can override any of the available virtual methods or not, as needed. At minimum @handle_frame needs to be overridden.

Members

Variables

GstReserved
void*[18] GstReserved;
convert
bool function(GstBaseParse* parse, GstFormat srcFormat, long srcValue, GstFormat destFormat, long* destValue) convert;

Optional. Convert between formats.

detect
GstFlowReturn function(GstBaseParse* parse, GstBuffer* buffer) detect;

Optional. Called until it doesn't return GST_FLOW_OK anymore for the first buffers. Can be used by the subclass to detect the stream format.

getSinkCaps
GstCaps* function(GstBaseParse* parse, GstCaps* filter) getSinkCaps;

Optional. Allows the subclass to do its own sink get caps if needed.

handleFrame
GstFlowReturn function(GstBaseParse* parse, GstBaseParseFrame* frame, int* skipsize) handleFrame;

Parses the input data into valid frames as defined by subclass which should be passed to gstbase.base_parse.BaseParse.finishFrame. The frame's input buffer is guaranteed writable, whereas the input frame ownership is held by caller (so subclass should make a copy if it needs to hang on). Input buffer (data) is provided by baseclass with as much metadata set as possible by baseclass according to upstream information and/or subclass settings, though subclass may still set buffer timestamp and duration if desired.

parentClass
GstElementClass parentClass;

the parent class

prePushFrame
GstFlowReturn function(GstBaseParse* parse, GstBaseParseFrame* frame) prePushFrame;

Optional. Called just prior to pushing a frame (after any pending events have been sent) to give subclass a chance to perform additional actions at this time (e.g. tag sending) or to decide whether this buffer should be dropped or not (e.g. custom segment clipping).

setSinkCaps
bool function(GstBaseParse* parse, GstCaps* caps) setSinkCaps;

Optional. Allows the subclass to be notified of the actual caps set.

sinkEvent
bool function(GstBaseParse* parse, GstEvent* event) sinkEvent;

Optional. Event handler on the sink pad. This function should chain up to the parent implementation to let the default handler run.

sinkQuery
bool function(GstBaseParse* parse, GstQuery* query) sinkQuery;

Optional. Query handler on the sink pad. This function should chain up to the parent implementation to let the default handler run (Since: 1.2)

srcEvent
bool function(GstBaseParse* parse, GstEvent* event) srcEvent;

Optional. Event handler on the source pad. Should chain up to the parent to let the default handler run.

srcQuery
bool function(GstBaseParse* parse, GstQuery* query) srcQuery;

Optional. Query handler on the source pad. Should chain up to the parent to let the default handler run (Since: 1.2)

start
bool function(GstBaseParse* parse) start;

Optional. Called when the element starts processing. Allows opening external resources.

stop
bool function(GstBaseParse* parse) stop;

Optional. Called when the element stops processing. Allows closing external resources.