After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 578118 - [multifdsink] add option to not resend the streamheader when it changes in the caps
[multifdsink] add option to not resend the streamheader when it changes in th...
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-base
git master
Other Linux
: Normal enhancement
: 0.10.23
Assigned To: Wim Taymans
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2009-04-06 10:07 UTC by Jan Urbański
Modified: 2009-04-14 15:06 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch to implement the feature (3.68 KB, patch)
2009-04-06 10:08 UTC, Jan Urbański
committed Details | Review

Description Jan Urbański 2009-04-06 10:07:23 UTC
The attached patch adds a new property in multifdsink, resend-streamheader.

If this property is false, the multifdsink will not send the streamheader if there's already one set for a particular client.

There are some formats in which every stream needs to start with a certain blob, but you can't inject this blob at leisure. If the producer wants to change the blob in question and sets in as the streamheader on the outgoing buffers' caps, new clients of multifdsink will get the new streamheader, but old clients will break, because they'll see the blob in the middle of the stream.

The property is true by default, so existing code will not see any difference.
Comment 1 Jan Urbański 2009-04-06 10:08:27 UTC
Created attachment 132177 [details] [review]
patch to implement the feature
Comment 2 Jan Urbański 2009-04-06 10:22:03 UTC
Actually, a better idea might be to invent a new buffer flag, something like DONT_SEND_IN_STREAMHEADER_IF_CHANGED.

multifdsink would then look at that flag and not send buffers that have it. The producer can then change the streamheader safely - new clients will get the new header, old clients won't get broken. That shifts the responsibility to the producer, which is good, and adds flexibility.
Comment 3 Wim Taymans 2009-04-09 22:04:50 UTC
The streamheader flag is hard to implement without breaking ABI for 0.10. I guess the patch is acceptable.
Comment 4 Wim Taymans 2009-04-14 15:06:43 UTC
commit 63108730a59c270e5ddce051722755ca1596ef14
Author: Jan Urbanski <j.urbanski at students.mimuw.edu.pl>
Date:   Tue Apr 14 17:04:06 2009 +0200

    multifdsink: add property to resend streamheaders
    
    Adds a new property in multifdsink, resend-streamheader.
    
    If this property is false, the multifdsink will not send the streamheader if
    there's already one set for a particular client.
    
    There are some formats in which every stream needs to start with a certain
    blob, but you can't inject this blob at leisure. If the producer wants to
    change the blob in question and sets in as the streamheader on the outgoing
    buffers' caps, new clients of multifdsink will get the new streamheader, but
    old clients will break, because they'll see the blob in the middle of the
    stream.
    
    The property is true by default, so existing code will not see any difference.
    
    Fixes #578118.