Failing to do so in the Windows case (implicitly triggered otherwise)
would have a subsequent _wait return immediately leading to high CPU
usage timeout loops.
Fixes#640675.
Make adding/removing gst_debug_log_default() work reliably in all
circumstances. The problem was that depending on platform and linker
flags the function argument might resolve to different addresses,
which made it impossible to remove the default log function added
in gst_init() from application code (because the pointer values
didn't match). The new approach should keep things simple by passing
NULL for the default function, which the code in libgstreamer can
then handle.
https://bugzilla.gnome.org/show_bug.cgi?id=625396https://bugzilla.gnome.org/show_bug.cgi?id=640771
Makes gst_bus_add_watch(), gst_bus_add_watch_full(), gst_bus_add_signal_watch(),
and gst_bus_add_signal_watch_full() convenience functions automatically pick up
any non-default main contexts set for the current thread via
g_main_thread_push_thread_default().
gstelement.c: In function ‘gst_element_get_request_pad’:
gstelement.c:1052:18: error: variable ‘tmp’ set but not used [-Werror=unused-but-set-variable]
https://bugzilla.gnome.org/show_bug.cgi?id=640850
The description string was changed to an inlined string a while back.
(But: no need to intern the const strings here, we just use the interning
to avoid allocating duplicates and make memory management easier,
since the strings will be around for the life-time of the app anyway).
https://bugzilla.gnome.org/show_bug.cgi?id=640071
Only replace existing plugins by blacklisted ones if they correspond
to the exact same plugin. If they're not the same, keep the existing
valid one.
Fixes#638941
Ignore plugins which have been moved into coreelements, so it's
still possible to just upgrade GStreamer core without having to
upgrade the whole stack.
This reverts commit f9039c2204.
We use -DG_DISABLE_ASSERTS for releases and pre-releases, but
don't want to disable pad name checking for releases in general,
I think. Need a better solution here. Fixes pad unit test in
pre-release/release mode.
Avoid unnecessary malloc/free to get the file basename on MSVC to avoid
unnecessary overhead when doing GST_DEBUG=foo:5 or so (since it would be
done before the category log level filtering).
The new request_new_pad_full vmethod provides an additional caps field,
which allows elements to take better decision process.
Also, add a gst_element_request_pad() function to allow developers to be
able to specify which pad template they want a pad of.
Convert gstutils to use that new method instead of the old one when more
efficient.
This is useful for being able to request pads in a more flexible way,
especially when the element can provide pads whose caps depend on
runtime configuration and therefore can't provide pre-registered
pad templates.
API: GstElement::request_new_pad_full
API: gst_element_request_pad
https://bugzilla.gnome.org/show_bug.cgi?id=637300
We need to reset the revents field of each pollfd when reading the results
from select else we'll end up with stray info from previous calls to
select.
Fix freeing of partially-inited list value when both values
passed are equal and we want to return a single non-list
value as result. Fixes unit test. Also fix up docs a bit.
https://bugzilla.gnome.org/show_bug.cgi?id=637776
The -Bsymbolic change causes us to get a different address when internaly
looking up the function than what application would get when the use the symbol
that they see. This made removing the default loghandler to fail, as it is set
internally and removed externaly.
All functions in this file can access the structure field of a query directly.
This avoids having to call gst_query_get_structure() to get it, along with being
able to remove some function variables that were used to store the result of that
function.
All functions in this file can access the structure field of an event directly.
This avoids having to call gst_query_get_structure() to get it, along with being
able to remove some function variables that were used to store the result of that
function.
There is no need to cache the peer chainfunction as we can just as efficiently
get to it from the peer object. Also not caching the chain function works better
because then we automatically get the new chainfunctions when they change.
Build the cache while we push data. When we don't have a cache, we run the
slowpath and collect cacheable properties. When all conditions are met, keep the
cached data around so that we can more efficiently push data around.
Fix returning of timezones on systems with gdatetime
to use floats on the math expression to avoid
truncating the fractional part.
Also adds a test for covering this case.
Otherwise the source will stay at NULL, the event is passed to the
peerpad via gst_pad_send_event() and then the peerpad is set as
source of the event instead of the originating pad.
This change always defines the restrict keyword if a
non-C99 C compiler is used. In the case of GCC >= 4
it will be defined to __restrict__, in all other
cases to nothing. This allows to use the restrict
keyword unconditionally.