Some presets are not always supported on all devices and will cause an error if
used. Specifically, the LOSSLESS presets are known to not work everywhere.
We weren't using the result of find_best_format at all.
Also, move the find_best_format usage to the default update_caps() to make
sure that it is also overridable.
https://bugzilla.gnome.org/show_bug.cgi?id=764363
This way we can use the base class for buffer allocation, hence use
fill() instead of create() virtual. This also adds a strict check on the
select pool buffer size as we don't support strides and padding.
This is based on initial patch proposed by Sebastien Dröge, from which I
also fixed a buffer pool leak.
https://bugzilla.gnome.org/show_bug.cgi?id=763441
As we currently only use the server reported "natural" format, caps
negotiation should simply be limited to telling the base class which
format to use. Fix the negotiation by moving the associated code
into negotiate() virtual function. Also, use gst_base_src_set_caps()
rather then setting it on the pad directly. Also protect against this
method being called multiple time (we can't renegotiate for now).
This change also moves some network code that was being run during the
application state change call, to be run on the streaming thread.
https://bugzilla.gnome.org/show_bug.cgi?id=739598
Although it's not very well documented, g_input_stream_read_all() will
set the number of bytes read to 0 if the connection is closed rather
then returning an error.
This prevents recursion on error. This used to happen as we
don't change the state when something fails. We end up running
and failing in the same state forever.
Using GSocketClient we can simplify a lot the read/write operation.
This also provide an GSocketConnection (a GIOStream) which can then
be used with the GTlsClientConnection for secure connections. Note
that we use _write_all() to ensure all bytes have been read. This is
to follow the fact the none of the _send() calls check the return
value.
When the security cannot be negotiated, the server returns
security type of 0 (failure). In that case, the next step is
to read the error reason string.
We have no idea which timestamps they are supposed to have so the only thing
we can do at this point is to drop them. Packets without timestamps happen if
audio was captured but no corresponding video, which shouldn't happen under
normal circumstances.
https://bugzilla.gnome.org/show_bug.cgi?id=747633
In this case the socket callback has not been called
by libcurl and the curlsink has not been notified about any
connection problems by libcurl.
This indicates that it's a bug in libcurl so catch it as
an unknown error.
https://bugzilla.gnome.org/show_bug.cgi?id=754432
Add namespace bgsegm, replacement functions and Template class for new
OpenCV versions because these functions have been removed. cvarrToMat() is
added because it is compatible with all versions of OpenCV and the use of
class Mat constructor is eliminated, it is also deprecated in 3.X versions.
Use the namespace cv because some functions are called many times.
This patch keeps compatibility with 2.4
https://bugzilla.gnome.org/show_bug.cgi?id=760473
The subsampling_x, subsampling_y, bit_depth, color_space and color_range
fileds are moved from GstVp9FrameHdr to the global GstVp9Parser structure.
These fields are only present in keyframe or intra-only frame, no need to
duplicate them for inter-frames. This is an ABI change.
https://bugzilla.gnome.org/show_bug.cgi?id=764370
imgproc_c.h is added because CvFont struct needs it in any 3.x version.
We use this structure in GstOpencvTextOverlay. This keeps compatibility
with 2.4.
https://bugzilla.gnome.org/show_bug.cgi?id=760473
We get into this code path if the profile is already constrained-baseline and
downstream does not support constrained-baseline. So we should try baseline
and the other compatible profiles.
https://bugzilla.gnome.org/show_bug.cgi?id=764448
while calling eglCreateImage without a GL context current in the executing
thread works on the RPi, some other implementations will return errors.
Marshall the eglCreateImage to the GL thread to appease these implementations.