Make sure we take ownership of the buffer early without increasing its refcount
when we go in the collect function. This reduces the amount of copies needed in
order to make the buffer writable in most cases.
In some cases we can avoid allocating a subbuffer and instead simply ref
the buffer. Callers should perform _make_metadata_writable() in all
cases now.
Add a method to install a clipping function that is called when a buffer is
received. Users of collectpads can then perform clipping on the incomming
buffers.
Also retab the header file a little.
See #590265
When we unblock a pad with the same user_data, the destroy callback is not
called. This leads to refcounting leaks that cannot be avoided. Instead always
call the destroy notify whenever we install a new pad block.
In particular, this fixes a nasty pad leak in decodebin2.
Also update the unit test to have more accurate comments and test the required
behaviour.
Adds the following new tags:
GST_TAG_SHOW_NAME
GST_TAG_SHOW_SORTNAME
GST_TAG_SHOW_EPISODE_NUMBER
GST_TAG_SHOW_SEASON_NUMBER
GST_TAG_LYRICS
GST_TAG_COMPOSER_SORTNAME
GST_TAG_GROUPING
Fixes#599759
Setting an object name is nice for proper debug logging. Ideally this would
still happens earlier (.e.g when pads are added to an element, its not yet set).
Never skip the state change to playing, even if the element is already in the
right state. We need this because we also distribute the base_time while doing
the state change and skipping this step would leave some elements without a new
base_time.
Fixes#600313
This allows demuxers to update the segment stop of an already
finished stream. This might be needed if some stream goes to
EOS before the duration of the longest stream is known to properly
set the segment stop of all streams to the same value in the end.
gst_value_list_size and gst_value_list_get_value will do a series of
extra checks due to being public methods.
When we use them from within gstvalue.c we can directly use them without
the extra checks.
Set the pad flushing and stop the pad task when the initial seek fails
during activation. Avoids racy calls into the _create() function when
BaseSrc::stop() has already run.
Fixes: #603059
Also, fix some misspelled comments.
gstfilesink.c:399: error: format ‘%d’ expects type ‘int’, but argument 8 has type ‘size_t’
gstfilesink.c:399: error: format ‘%d’ expects type ‘int’, but argument 9 has type ‘gsize’
gstfilesrc.c:588: error: format ‘%08llx’ expects type ‘long long unsigned int’, but argument 8 has type ‘off_t’
It is not easy to setup a tee on the fly, thus apps need to add them always if
they might need them. This changes the code so, that if only one src-pad is
active, we push buffers directly. In the normal code path all buffers are pushed
with an extra ref, that forces followup inplace elements to copy the data.