gst/gstmemory.c:570:38: error: implicit conversion from enumeration type 'GstMapFlags' to different enumeration
type 'GstLockFlags' [-Werror,-Wenum-conversion]
fail_unless (gst_memory_lock (mem, GST_MAP_WRITE));
~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~
This uses all of the netclientclock code, except for the generation and
parsing of packets. Unfortunately some code duplication was necessary
because GstNetTimePacket is public API and couldn't be extended easily
to support NTPv4 packets without breaking API/ABI.
We extend our calculations to work with local send time, remote receive time,
remote send time and local receive time. For the netclientclock protocol,
remote receive and send time are assumed to be the same value.
For the results, this modified calculation makes absolutely no difference
unless the two remote times are different.
This improves accuracy on wifi or similar networks, where the RTT can go very
high up for a single observation every now and then. Without filtering them
away completely, they would still still modify the average RTT, and thus all
clock estimations.
They don't necessarily use the same underlying clocks (e.g. on Windows), or
might be configured to a different clock type (monotonic vs. real time clock).
We need the values a clean system clock returns, as those are the values used
by the internal clocks.
gst-indent used to support gnuindent and indent as executable names.
However, on OSX one can "brew install gnu-indent" and then the
executable name will be gindent. Added support for that.
https://bugzilla.gnome.org/show_bug.cgi?id=750351
If the delay measurement is too far away from the median of the window of last
delay measurements, we discard it. This increases accuracy on wifi a lot.
https://bugzilla.gnome.org/show_bug.cgi?id=749391
We should do some more measurements with all these and check how much sense
they make for PTP. Also enabling them means not following IEEE1588-2008 by the
letter anymore.
https://bugzilla.gnome.org/show_bug.cgi?id=749391
GstPtpClock implements a PTP (IEEE1588:2008) ordinary clock in
slave-only mode, that allows a GStreamer pipeline to synchronize
to a PTP network clock in some specific domain.
The PTP subsystem can be initialized with gst_ptp_init(), which then
starts a helper process to do the actual communication via the PTP
ports. This is required as PTP listens on ports < 1024 and thus
requires special privileges. Once this helper process is started, the
main process will synchronize to all PTP domains that are detected on
the selected interfaces.
gst_ptp_clock_new() then allows to create a GstClock that provides the
PTP time from a master clock inside a specific PTP domain. This clock
will only return valid timestamps once the timestamps in the PTP domain
are known. To check this, the GstPtpClock::internal-clock property and
the related notify::clock signal can be used. Once the internal clock
is not NULL, the PTP domain's time is known. Alternatively you can wait
for this with gst_ptp_clock_wait_ready().
To gather statistics about the PTP clock synchronization,
gst_ptp_statistics_callback_add() can be used. This gives the
application the possibility to collect all kinds of statistics
from the clock synchronization.
https://bugzilla.gnome.org/show_bug.cgi?id=749391
gst_clock_wait_for_sync(), gst_clock_is_synced() and gst_clock_set_synced()
plus a signal to asynchronously wait for the clock to be synced.
This can be used by clocks to signal that they need initial synchronization
before they can report any time, and that this synchronization can also get
completely lost at some point. Network clocks, like the GStreamer
netclientclock, NTP or PTP clocks are examples for clocks where this is useful
to have as they can't report any time at all before they're synced.
https://bugzilla.gnome.org/show_bug.cgi?id=749391
There are gstmemory's available that operate in two memory domains
and need to ensure consistent access between these domains.
Imagine a scenario where e.g. the GLMemory is mapped twice in both
the GPU and the CPU domain. On unmap or a subsequent map, it would
like to ensure that the most recent data is available in the memory
domain requested. Either by flushing the writes and/or initiating a
DMA transfer. Without knowing which domain is being unmapped, the
memory does not know where the most recent data is to transfer to
the other memory domain.
Note: this still does not allow downgrading a memory map.
https://bugzilla.gnome.org/show_bug.cgi?id=750319
Now that locking exclusively dows not always succeed, we need to signal
the failure case from gst_memory_init.
Rather than introducing an API or funcionality change to gst_memory_init,
workaround by checking exclusivity in the calling code.
https://bugzilla.gnome.org/show_bug.cgi?id=750172
gst_memory_lock (mem, WRITE | EXCLUSIVE);
gst_memory_lock (mem, WRITE | EXCLUSIVE);
Succeeds when the part-miniobject.txt design doc suggests that this should fail:
"A gst_mini_object_lock() can fail when a WRITE lock is requested and
the exclusive counter is > 1. Indeed a GstMiniObject object with an
exclusive counter 1 is locked EXCLUSIVELY by at least 2 objects and is
therefore not writable."
https://bugzilla.gnome.org/show_bug.cgi?id=750172
DllMain should not be relied on for anything except storing the DLL handle.
It should also not be defined for static builds, but doing so is not
straightforward and is mostly harmless, so let's just add a comment about that
for now.
GstFlagSet is a new type designed for negotiating sets
of boolean capabilities flags, consisting of a 32-bit
flags bitfield and 32-bit mask field. The mask field
indicates which of the flags bits an element needs to have
as specific values, and which it doesn't care about.
This allows efficient negotiation of arrays of boolean
capabilities.
The standard serialisation format is FLAGS:MASK, with
flags and mask fields expressed in hexadecimal, however
GstFlagSet has a gst_register_flagset() function, which
associates a new GstFlagSet derived type with an existing
GFlags gtype. When serializing a GstFlagSet with an
associated set of GFlags, it also serializes a human-readable
form of the flags for easier debugging.
It is possible to parse a GFlags style serialisation of a
flagset, without the hex portion on the front. ie,
+flag1/flag2/flag3+flag4, to indicate that
flag1 & flag4 must be set, and flag2/flag3 must be unset,
and any other flags are don't-care.
https://bugzilla.gnome.org/show_bug.cgi?id=746373
Just create the cancellable fd once and keep it around instead
of creating/closing it for every single packet. Since we spend
most time waiting for packets, an fd is alloced and in use pretty
much all the time anyway.