TagList.getSample

bool getSample(string tag, out gst.sample.Sample sample)

Copies the first sample for the given tag in the taglist into the variable pointed to by sample. Free the sample with gst_sample_unref() when it is no longer needed. You can retrieve the buffer from the sample using [gst.sample.Sample.getBuffer] and the associated caps (if any) with [gst.sample.Sample.getCaps].

Free-function: gst_sample_unref

Parameters

tagtag to read out
sampleaddress of a GstSample pointer variable to store the result into

Returns

true, if a sample was returned, false if the tag didn't exist in

the given list or if it was null.