summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: c38fbf8)
raw | patch | inline | side by side (parent: c38fbf8)
author | Mark Nauwelaerts <mark.nauwelaerts@collabora.co.uk> | |
Mon, 10 Jan 2011 16:07:38 +0000 (17:07 +0100) | ||
committer | Tim-Philipp Müller <tim.muller@collabora.co.uk> | |
Fri, 8 Apr 2011 14:44:54 +0000 (15:44 +0100) |
... and document accordingly.
gst/audioparsers/gstbaseparse.c | patch | blob | history |
index a4505c197bc60479377e207d1332b53aeeb5c4e0..ac9d7f2e1404da74f372f03cbb6eadc8495e3a0c 100644 (file)
* frame contents and setting the caps, and buffer metadata (e.g.
* buffer timestamp and duration, or keyframe if applicable).
* (although the latter can also be done by GstBaseParse if it is
- * appropriately configured, see below).
+ * appropriately configured, see below). Frame is provided with
+ * timestamp derived from upstream (as much as generally possible),
+ * duration obtained form configuration (see below), and offset
+ * if meaningful (in pull mode).
* </para></listitem>
* <listitem><para>
* Finally the buffer can be pushed downstream and parsing loop starts
GST_BUFFER_OFFSET (buffer), GST_BUFFER_OFFSET (buffer),
GST_BUFFER_SIZE (buffer));
+ /* use default handler to provide initial (upstream) metadata */
+ gst_base_parse_parse_frame (parse, frame);
+
/* store offset as it might get overwritten */
offset = GST_BUFFER_OFFSET (buffer);
ret = klass->parse_frame (parse, frame);
}
}
- /* re-use default handler to add missing metadata as-much-as-possible */
+ /* again use default handler to add missing metadata;
+ * we may have new information on frame properties */
gst_base_parse_parse_frame (parse, frame);
if (GST_BUFFER_TIMESTAMP_IS_VALID (buffer) &&
GST_BUFFER_DURATION_IS_VALID (buffer)) {