typeFindHelperGetRange

fngst.caps.Caps typeFindHelperGetRange(gst.object.ObjectWrap obj, gst.object.ObjectWrap parent, gstbase.types.TypeFindHelperGetRangeFunction func, ulong size, string extension, out gst.types.TypeFindProbability prob)

Utility function to do pull-based typefinding. Unlike [gstbase.global.typeFindHelper] however, this function will use the specified function func to obtain the data needed by the typefind functions, rather than operating on a given source pad. This is useful mostly for elements like tag demuxers which strip off data at the beginning and/or end of a file and want to typefind the stripped data stream before adding their own source pad (the specified callback can then call the upstream peer pad with offsets adjusted for the tag size, for example).

When extension is not null, this function will first try the typefind functions for the given extension, which might speed up the typefinding in many cases.

Free-function: gst_caps_unref

Parameters

objA #GstObject that will be passed as first argument to func
parentthe parent of obj or null
funcA generic #GstTypeFindHelperGetRangeFunction that will be used to access data at random offsets when doing the typefinding
sizeThe length in bytes
extensionextension of the media, or null
problocation to store the probability of the found caps, or null

Returns

the #GstCaps corresponding to the data

stream. Returns null if no #GstCaps matches the data stream.