[ CCode ( cname = "gst_type_find_helper_for_buffer_with_extension" ) ]
[ Version ( since = "1.16" ) ]
public Caps? type_find_helper_for_buffer_with_extension (Object? obj, Buffer buf, string? extension, out TypeFindProbability prob)

Tries to find what type of data is contained in the given Buffer, the assumption being that the buffer represents the beginning of the stream or file.

All available typefinders will be called on the data in order of rank. If a typefinding function returns a probability of MAXIMUM, typefinding is stopped immediately and the found caps will be returned right away. Otherwise, all available typefind functions will the tried, and the caps with the highest probability will be returned, or null if the content of the buffer could not be identified.

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



object doing the typefinding, or null (used for logging)


a Buffer with data to typefind


extension of the media, or null


location to store the probability of the found caps, or null


the Caps corresponding to the data, or null if no type could be found. The caller should free the caps returned with gst_caps_unref.

Namespace: Gst.Base