Commit graph

5153 commits

Author SHA1 Message Date
Matthew Waters
6ab40e8531 qt: specify that we currently only take 2D textures
Fixes black screen video playback on android without a caps filter.
2016-01-27 16:13:28 +11:00
Matthew Waters
3cf98f7e5e glvideoflip: incorporate the aspect ratio into the scale_x calculations
1. Otherwise rotating the video will clip and show black bars due to
   gltransformation's implementation.
2. The other option of make gltransformation aspect-agnostic produces
   incorrect output with perspective transformations.
2016-01-27 16:13:28 +11:00
Luis de Bethencourt
a152a8342b opencv: add mask property to cvlaplace
Add a "mask" property that sets whether the edges by cvLaplace should be
used as a mask on the original input or not. The same way the original
image is copied to the edges in edgedetect.
2016-01-25 22:30:44 +00:00
Luis de Bethencourt
9301d5874a opencv: add mask property to cvsobel
Add a "mask" property that sets whether the detected derivative edges
should be used as a mask on the original input or not. The same way
the original image is added to the edges in edgedetect.
2016-01-25 21:43:09 +00:00
Luis de Bethencourt
e90b383060 opencv: update deprecated function in skindetect
cvCvtPixToPlane() has been deprecated in OpenCV 3.0, and cvSplit() is the
suggested replacement. Since cvSplit() is available in OpenCV 2.4, it is
safe and cautious to update the function usage before it becomes an issue.
2016-01-25 15:23:10 +00:00
Luis de Bethencourt
36e83661ec opencv: fix cvlaplace
cvlaplace was also affected by the silent change in OpenCV API, same as
cvsobel. It hasn't been working for a while. It would return a plain black
image. This commit updates the usage of cvLaplace by using cvCvtColor to
create the grayscale intermediate image to process. This also means there
is no need anymore to use GstBaseTransform's transform_caps, since the pads
are RGB.
2016-01-25 14:20:14 +00:00
Luis de Bethencourt
e294866bd7 opencv: fix cvsobel
cvsobel han't been working for a while due to a silent change in OpenCV
API. It would return a plain black image. This commit updates the usage
of cvSobel by using cvCvtColor to create the grayscale image to process.
This also means there is no need to use GstBaseTransform's transform_caps
anymore, since the pads can be RGB.
2016-01-24 23:19:18 +00:00
John Chang
8e788f2845 mpdparser: Use RepresentationIndex instead of Initialization to get the URL of the RepresentationIndex
https://bugzilla.gnome.org/show_bug.cgi?id=760936
2016-01-22 17:45:26 +02:00
Sebastian Dröge
5b04e77c0c spandsp: Add tone generator 2016-01-21 16:53:41 +02:00
Tim-Philipp Müller
6e79d54ae5 gl: fix compiler warnings with gcc-6
In file included from effects/gstgleffectrgbtocurve.c:25:0:
effects/gstgleffectscurves.h:174:32: error: 'xray_curve' defined but not used
 static const GstGLEffectsCurve xray_curve = {
...
2016-01-19 13:20:23 +00:00
Florin Apostol
88f509a710 dashdemux: added check that availabilityStartTime is present for live streams
https://bugzilla.gnome.org/show_bug.cgi?id=757602
2016-01-18 15:12:07 -03:00
Florin Apostol
2918dff2e0 adaptivedemux: improved error message if availabilityStartTime is missing for a live stream
For a live mpd, if availabilityStartTime is missing, adaptive demux asserts
with: Unexpected critical/warning: gst_date_time_to_g_date_time: assertion
'datetime != NULL' failed.

This patch improves the error message to:
Unexpected critical/warning: gst_mpd_client_seek_to_time: assertion
'client->mpd_node->availabilityStartTime != NULL' failed

https://bugzilla.gnome.org/show_bug.cgi?id=757602
2016-01-18 15:12:07 -03:00
Thiago Santos
b7a0be23c6 adaptivedemux: replace ghostpad with a standard pad
Handling the ghostpad and its internal pad was causing more issues
than helping because of their coupled activation/deactivation
actions.

As we have to install custom chain,event and query functions it is
better to use a floating sink pad internally in the demuxer and just
use those pad functions to push through a standard pad in the demuxer

https://bugzilla.gnome.org/show_bug.cgi?id=757951
2016-01-15 11:32:37 -03:00
Sergey Borovkov
155f0acfab qml: Mark material dirty when texture buffer is updated
Qt might not redraw the scene otherwise.

https://bugzilla.gnome.org/show_bug.cgi?id=758286
2016-01-15 14:11:52 +11:00
Matthew Waters
0b9ae1f1d6 gl: add a videoflip element
Behaves exactly the same as the non-GL videoflip element
2016-01-15 12:05:03 +11:00
Matthew Waters
198d451f31 gltransformation: always build a valid mvp matrix
The default case is to build an identity matrix.
2016-01-15 12:05:02 +11:00
Matthew Waters
f721499371 gltransformation: support negative scales
A scale of -1.0 means to flip the video.
2016-01-15 12:05:02 +11:00
Matthew Waters
12f013c8d7 gltransformation: implement passthrough handling 2016-01-15 12:05:02 +11:00
Matthew Waters
066f0dcda0 gltransformation: implement navigation events
Reverses the transformation applied through the properties and forwards the
event.

The process for finding the coordinates on the video are as follows:
1. Convert the given pointer_x and pointer_y to model space at the near and far planes
2. Get the equation of the video plane
3. Find where the ray in 1 intersects the plane
4. Profit!
2016-01-15 12:04:59 +11:00
Matthew Waters
4cfb6b9166 glimagesink: remove reduntant glimagesink from debug logging 2016-01-14 17:52:23 +11:00
Matthew Waters
1bb2985777 gl: implement a colorbalance element
It performs the exact same operation as videobalance but with opengl shaders and
was tested with glvideomixer by comparing frames from videobalance and
glcolorbalance.
2016-01-13 12:00:03 +11:00
Matthew Waters
ceec4ad873 glvideomixer: implement glBlendFunc and glBlendEquation
Allows more blending options than just A over B

e.g. frame comparisons are now possible.
  glvideomixer name=m
    sink_0::zorder=0
    sink_1::zorder=1
    sink_1::blend-equation-rgb={subtract,reverse-subtract}
    sink_1::blend-function-src-rgb=src-color
    sink_1::blend-function-dst-rgb=dst-color
  ! glimagesinkelement
  videotestsrc pattern=checkers-4 ! m.sink_0
  videotestsrc pattern=checkers-8 ! m.sink_1
2016-01-13 12:00:03 +11:00
Tim Sheridan
95a14fd470 sbc: sbcdec: Fix frame length calculation
SBC frame length calculation wasn't being rounded up to the nearest byte
(as specified in the A2DP 1.0 specification, section 12.9). This could
cause 'stereo' and 'joint stereo' mode SBC streams to have incorrectly
calculated frame lengths.

https://bugzilla.gnome.org/show_bug.cgi?id=742446
2016-01-12 21:45:05 +00:00
Luis de Bethencourt
8c7ea6fb87 opencv: remove check for OpenCV version
After commit 64080e632, configure checks for all the header files that
should be available in OpenCV 2.3 and later. If any of these files isn't
there the OpenCV elements won't be part of the build.

No need to recheck for opencv2/legacy/legacy.hpp again in
gstpyramidsegment.h. Minimum supported OpenCV version must have this header
and configure already checks for it. Removing check.
2016-01-08 17:12:04 +00:00
Luis de Bethencourt
94c07ed229 opencv: always do cvsmooth in place
After the update to new OpenCV API the transform function using an out
buffer is not necessary. We can always do the transformation in place.
2016-01-08 15:01:52 +00:00
Luis de Bethencourt
14dd6b7088 opencv: do pyramidsegment's transformation in place
Run the transform function of pyramidsegment in place, reusing the image
data as both source and destination in cvPyrSegmentation. This avoids
copying the image back and forth and the extra memory.
2016-01-08 12:39:55 +00:00
Tim-Philipp Müller
17f0faa368 hlsdemux: put boolean values into gboolean variables
And remove superfluous assignments.
2016-01-06 15:25:04 +00:00
Thiago Santos
bf57be7fc7 hlsdemux: fix reverse playback seek with snap flags
Properly handle snap flags during reverse seeking. In this case
the before/after are also reversed, so handle those as such.

For example: with a sequence of 1s fragments:

|-- 0 --|-- 1 --|-- 2 --|-- 3 --|

If you seek to 1.5s it is inside fragment 1. With reverse and

snap-before: should play from the end of fragment 1
snap-after: should play from the end of fragment 0
2016-01-06 10:23:13 -03:00
Thiago Santos
5d87f68f6c hlsdemux: simplify snap flags checking
Replace:
if (boolean) var = true;

with:
var = (boolean);
2016-01-06 10:23:13 -03:00
Thiago Santos
b8e0c365c4 hlsdemux: respect keyunit flag for position
Set the segment start position when keyunit flag is active
2016-01-06 10:23:13 -03:00
Matthew Waters
519280204c glcolorconvert: implement usage of a buffer pool
Saves unnecessary glGenTextures and glDeleteTextures which may have a
non-trivial cost.
2016-01-06 16:48:33 +11:00
Reynaldo H. Verdejo Pinochet
8c78a79c67 rtmp: refer to both elements in the README 2015-12-30 18:00:47 -08:00
Reynaldo H. Verdejo Pinochet
00587eb561 rtmpsrc: check for failed RTMP context alloc
Avoids an unlikely crash.

Arguably, if allocation fails we have no chance of
recovering but nonetheless, RTMP_Alloc can fail and
librtmp's RTMP_init() (called next) assumes a non-NULL
pointer is passed without checking.

Additionally, unify exit path on error.
2015-12-30 17:22:54 -08:00
Reynaldo H. Verdejo Pinochet
17da1ad409 rtmpsink: check for failed RTMP context alloc
Avoids an unlikely crash.

Arguably, if allocation fails we have no chance of
recovering but nonetheless, RTMP_Alloc can fail and
librtmp's RTMP_init() (called next) assumes a non-NULL
pointer is passed without checking.

Additionally, unify exit path on error.
2015-12-30 17:22:42 -08:00
Reynaldo H. Verdejo Pinochet
4b93a7167f rtmp: correct librtmp log-level mappings
Additionally, move to a switch in _set_debug_level()
to make easier to follow and compare with the
mappings in _log_callback()
2015-12-30 16:12:27 -08:00
Matthew Waters
8c02a47741 gleffects: fix shader compilation with legacy opengl
All the gleffects shaders can be run against a gles2 or a legacy opengl glsl
compiler but weren't being advertised as such.

Fixes gleffects under desktop opengl < 3.2.
2015-12-30 12:16:29 +11:00
Florin Apostol
ef06d2a855 dashdemux: removed unnecessary space trimming in gst_dash_demux_parse_http_head
sscanf has removed all spaces when it has constructed zone string. There is
no need to search for leading spaces.

https://bugzilla.gnome.org/show_bug.cgi?id=759743
2015-12-28 14:10:58 +02:00
Florin Apostol
09b21eacae dashdemux: accept 2 or 4 digit year when using HTTP HEAD for calculating clock compensation
Convert year from 2 digits to 4 digits in gst_dash_demux_parse_http_head

https://bugzilla.gnome.org/show_bug.cgi?id=759743

Also updated references to Rfc822 to Rfc5322
2015-12-28 14:10:58 +02:00
Florent Thiéry
15a28c8024 glshader: fix usage doc
The property location has been changed in favor of vertex/fragment
string properties; the doc had not been updated and was still referring
to the previous property; also, now the #version header has become mandatory

https://bugzilla.gnome.org/show_bug.cgi?id=759902
2015-12-28 10:43:56 +02:00
Florent Thiéry
c68e842ed0 glimagesink: Post unhandled navigation events on the bus
Based off xvimagesink implementation

https://bugzilla.gnome.org/show_bug.cgi?id=759869
2015-12-28 10:04:33 +02:00
Reynaldo H. Verdejo Pinochet
77b7864670 motioncells: fix splitting of RGB color string
No need to attempt splitting the RGB string in 255 tokens
if we only expect 3.

Left max_tokens at 4 to preserve the current logic (which
allows for extra stuff at the end) and added a warning on
parsing failure instead of silently discarding the value.
2015-12-27 23:26:50 -08:00
Reynaldo H. Verdejo Pinochet
5515a96167 motioncells: fix typo in header 2015-12-27 23:26:50 -08:00
Reynaldo H. Verdejo Pinochet
c0ced1590d motioncells: fix misleading warning message
calculate_motion != FALSE means the motion computation
logic is disabled, not a mapping error.
2015-12-27 23:26:50 -08:00
Reynaldo H. Verdejo Pinochet
8f3392ba44 motioncells: rework property descriptions 2015-12-27 23:26:50 -08:00
Reynaldo H. Verdejo Pinochet
c788678059 motioncells: use NULL instead of g_strdup(NULL) 2015-12-27 23:26:50 -08:00
Alex Ashley
f6bff8f5f5 hlsdemux: unquote all the quoted-string attributes
The URI attribute from the EXT-X-KEY tag and the URI attribute from the
EXT-X-I-FRAMES-ONLY tag are both quoted-string attibutes that have their
quotation marks removed during parsing. The CODECS attribute of the
EXT-X-STREAM-INF is also a quoted-string attribute, but this attribute
was not being un-quoted.

This commit changes the parser to always unquote all quoted-string
attributes and adjusts the unit tests to this new bevahiour for the
CODECS attribute.

An additional test is added to check that parsing of all of the fields
in the EXT-X-STREAM tag is correct, including those that contain comma
characters.

https://bugzilla.gnome.org/show_bug.cgi?id=758384
2015-12-22 11:15:32 -03:00
Thiago Santos
a072101441 hlsdemux: make sure every bad update_playlist return sets an error
Otherwise it segfaults when reporting the error in the bus
2015-12-22 10:16:16 -03:00
Sebastian Dröge
11729cde80 teletextdec: Use NULL instead of g_strdup('\0')
Which is equivalent to g_strdup(NULL).

https://bugzilla.gnome.org/show_bug.cgi?id=759728
2015-12-21 13:57:04 +01:00
Tim-Philipp Müller
384987341b assrender, dvbsuboverlay: fix example pipelines in docs 2015-12-19 21:25:49 +00:00
Tim-Philipp Müller
d5e115171b hlsdemux: reflow update_playlist a bit
Reduce indentation by erroring out directly on failure.
2015-12-19 21:12:17 +00:00