I am interested in video subregion information. I had plan to add caps to do this. Now you may help to estimate the feasibility of this plan. <br>Adding 5 caps, x, y, subwidth, subheight, first data byte offset in original video. substream tests these caps, if they are zeros, then ignores subregion information. Otherwise we operate subregion according to these information.
<br><br><br><div><span class="gmail_quote">2008/1/16, Stefan Kost &lt;<a href="mailto:ensonic@hora-obscura.de">ensonic@hora-obscura.de</a>&gt;:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi,<br><br>Jan Schmidt schrieb:<br>&gt; &lt;quote who=&quot;Stefan Kost&quot;&gt;<br>&gt;<br>&gt;&gt; hi,<br>&gt;&gt;<br>&gt;&gt; I am looking for a way to send some private data along with a buffer.<br>&gt;&gt; During data capture I get some metadata about capture settings and I would
<br>&gt;&gt; like to store/analyze them later along with the data stream. I tried to add<br>&gt;&gt; a payload item to caps and put a GstBuffer there. But this seems to be<br>&gt;&gt; painful and I am afraid that it will cause renegotiation as the content
<br>&gt;&gt; changes for each buffer. Has anyone been doing something similar?<br>&gt;&gt;<br>&gt;&gt; alternative (better approach) seems to be using a buffer subclass, right?<br>&gt;&gt;<br>&gt;&gt; Attached is my current test. Its a bit hackish and fails. One thing I was
<br>&gt;&gt; wondering is that fakesrc send buffer with caps=NULL. A bug?<br>&gt;&gt;<br>&gt;<br>&gt;&gt;From time to time, I&#39;ve thought about adding something like this directly<br>&gt; to GstBuffer, for carrying information whose presence been negotiated in
<br>&gt; the caps, but whose content should be allowed to change without<br>&gt; renegotiating.<br>&gt;<br>&gt; Examples:<br>&gt;&nbsp;&nbsp; * Pan and scan (video subregion) position information<br>&gt;&nbsp;&nbsp; * interlacing markers (top field, bottom field)
<br>&gt;&nbsp;&nbsp; * theora granulepos, instead of slapping it in the &#39;offset&#39; field<br>&gt;&nbsp;&nbsp; * MPEG Decoding timestamps, which we currently never send along.<br>&gt;<br>&gt; My thought was to add a GstStructure to GstBuffer which is allowed to be
<br>&gt; NULL.<br>&gt;<br>&gt; Wim has expressed concern that it would cause performance issues, and it<br>&gt; would certainly require extending various bits of GStreamer to support<br>&gt; properly (buffer serialisation/deserialisation in GDP, for example). Also,
<br>&gt; the semantics of how to handle the &#39;extradata&#39; when transforming a buffer<br>&gt; need to be clearly defined, ie the extradata has to be clearly specified<br>&gt; by the caps attached to the buffer, and there needs to be a way for it to
<br>&gt; be handled by elements that don&#39;t understand the extradata they&#39;ve been<br>&gt; given. It can&#39;t just be a dumping ground in which to place arbitrary data,<br>&gt; or I don&#39;t think it can be made to work.
<br>&gt;<br>&gt; J.<br>&gt;<br>Maybe some GstTaglist features can help. I am thinking of the merge-modes here.<br>Atleast this is needed when mixing data.<br><br>No idea how to express constraints that would render the data useless. 
E.g.<br>muxing two streams removes the &#39;frame&#39; context from video frames. Thus the muxer<br>would not copy/merge the extra-data to outgoing buffers.<br><br>I am not so much concerned with performance. In most cases it would not be used.
<br>Freeing buffers would need to release the taglst if its not NULL. Copying<br>buffers need to copy it.<br><br>As we have hierarchical structures now, we could probably require that the<br>producer uses its element name as a root tag. This way the taglist could carry
<br>multiple data-sets identified in a unique way. Elements that can use the data<br>need to know the name of the element that created it.<br><br>I&#39;ll think more about it - may be we can use our shiny new wiki to draft it :)
<br><br>Stefan<br><br><br>-------------------------------------------------------------------------<br>This SF.net email is sponsored by: Microsoft<br>Defy all challenges. Microsoft(R) Visual Studio 2008.<br><a href="http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/">
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/</a><br>_______________________________________________<br>gstreamer-devel mailing list<br><a href="mailto:gstreamer-devel@lists.sourceforge.net">gstreamer-devel@lists.sourceforge.net
</a><br><a href="https://lists.sourceforge.net/lists/listinfo/gstreamer-devel">https://lists.sourceforge.net/lists/listinfo/gstreamer-devel</a><br></blockquote></div><br>