Commit graph

7072 commits

Author SHA1 Message Date
Sebastian Dröge
43736e5c37 h265parse: Ensure codec_data has the required size when reading number of NAL arrays
https://bugzilla.gnome.org/show_bug.cgi?id=774896
2016-11-23 10:53:46 +02:00
Sebastian Dröge
1dbfef93d6 h264parse: Ensure codec_data has the required size when reading number of SPS
https://bugzilla.gnome.org/show_bug.cgi?id=774896
2016-11-23 10:53:40 +02:00
Sebastian Dröge
ee300b6c33 mpegtspacketizer: Reset values before parsing each section 2016-11-22 13:00:21 +02:00
Sebastian Dröge
ab4bb225bd mpegtspacketizer: Make sure in all cases that we have enough data left for reading a section start
In some cases we ended up parsing sections without.
2016-11-22 12:56:03 +02:00
Sebastian Dröge
0f657cec07 vc1parse: Mark pad as needing reconfiguration again if it failed
And return FLUSHING instead of NOT_NEGOTIATED on flushing pads.

https://bugzilla.gnome.org/show_bug.cgi?id=774623
2016-11-18 12:22:44 +02:00
Thibault Saunier
ca3020cf46 videomeasure: Remove old unported videomeasure plugin as it is now replaced by IQA 2016-11-17 13:25:40 -03:00
Sebastian Dröge
4cb1bcf142 vmncdec: Sanity-check width/height before using it
We will allocate a screen area of width*height*bpp bytes, however this
calculation can easily overflow if too high width or height are given
inside the stream. Nonetheless we would just assume that enough memory
was allocated, try to fill it and overwrite as much memory as wanted.

Also allocate the screen area filled with zeroes to ensure that we start
with full-black and not any random (or not so random) data.

https://scarybeastsecurity.blogspot.gr/2016/11/0day-poc-risky-design-decisions-in.html

Ideally we should just remove this plugin in favour of the one in
gst-libav, which generally seems to be of better code quality.

https://bugzilla.gnome.org/show_bug.cgi?id=774533
2016-11-16 20:41:39 +02:00
Sebastian Dröge
b957c336e5 smoothwave: Remove empty directory 2016-11-16 16:45:27 +02:00
Sebastian Dröge
734d98eaf1 real: Remove empty directory 2016-11-16 16:33:41 +02:00
Sebastian Dröge
ca6e47e63b mpeg1sys: Remove obsolete, empty directory that only contains a meson.build 2016-11-16 16:15:34 +02:00
Scott D Phillips
e4407d4599 Fix some MSVC warnings about const-ness
Some miscellaneous warnings about const-ness, either casting away const
where we know it's safe or removing const where it's not correct.

https://bugzilla.gnome.org/show_bug.cgi?id=774293
2016-11-15 14:53:49 +02:00
Scott D Phillips
0345fb8aef mpegtsdemux: fix operator precedence in SAFE_FOURCC_ARGS
Type cast has higher precedence than bitwise shift, so the third
argument will truncate to 8 bits and then shift right by 8 bits
resulting in constant zero.

https://bugzilla.gnome.org/show_bug.cgi?id=774293
2016-11-12 10:53:02 +02:00
Sebastian Dröge
4899bf0926 gst: Fix more mentions of interlaced-mode to say interlace-mode 2016-11-04 16:26:50 +02:00
Tim-Philipp Müller
d42177c89e bayer: fix stride inconsistencies for odd widths
Consistently use GST_ROUND_UP_4(width) as stride for
bayer buffers. Bayer data will usually come in widths
that are multiples of 4 anyway, so hopefully this
should not have any adverse impact on anyone in
practice.

Before, bayer2rgb required input buffers to are sized
accordingly, but then didn't actually round up when
calculating row offsets. rgb2bayer didn't use a rounded
stride nor buffer size.

https://bugzilla.gnome.org/show_bug.cgi?id=752014
2016-11-01 19:35:47 +02:00
Tim-Philipp Müller
2f8709d057 rawparse: pass flow returns upstream
rawvideoparse wouldn't error out on not-negotiated,
but would just keep on going, because it didn't pass
the flow return value back to the parent class and
thus upstream, so the source wouldnt' stop streaming.
2016-10-29 11:31:28 +01:00
Nirbheek Chauhan
bb0a83b018 plugins: Use explicit type conversion from enums
MSVC warns about this because it's a C++ compiler, and this actually
results in useful things such as the incorrect 'gboolean' return value
for functions that return GstFlowReturn, so let's do explicit
conversions to reduce the noise and increase its efficacy.
2016-10-27 23:06:26 +05:30
Nirbheek Chauhan
f790863755 Explicitly define float constants as float
With MSVC, this gives the following warning:

warning C4305: 'function': truncation from 'double' to 'gfloat'

Apparently, MSVC does not figure out what type to use for constants
based on the assignment. This warning is very spammy, so let's try to
fix it.
2016-10-27 23:06:26 +05:30
Nirbheek Chauhan
4b903f0cf3 meson: Add missing gstvideo dep to segmentclip
In file included from ../subprojects/gst-plugins-base/gst-libs/gst/video/video.h:27:0,
                 from ../subprojects/gst-plugins-bad/gst/segmentclip/gstvideosegmentclip.c:25:
../subprojects/gst-plugins-base/gst-libs/gst/video/video-format.h:27:39: fatal error: gst/video/video-enumtypes.h: No such file or directory
 #include <gst/video/video-enumtypes.h>
                                       ^
compilation terminated.

https://ci.gstreamer.net/job/GStreamer-master-meson/269/console
2016-10-18 13:01:04 +05:30
Vincent Penquerc'h
1630d2a0d7 mpegtsmux: fix buffer size mismatch in M2TS mode
In M2TS mode, we need an extra 4 bytes in the buffer, so need
to ensure the buffer can contain these. The allocation site
does not know the mode, so this is done in all cases.
2016-10-17 12:32:58 +01:00
Joan Pau Beltran
32b356b2c5 bayer: fix _transform_caps method to preserve fields in given caps
https://bugzilla.gnome.org/show_bug.cgi?id=758717
2016-10-14 09:45:15 -04:00
Edward Hervey
6622e2dacf mpegtsdemux: Implement efficient program updates
If the parent bin can handle it, only add/remove the new/gone stream
instead of re-adding/re-moving everything

https://bugzilla.gnome.org/show_bug.cgi?id=772742
2016-10-12 15:07:46 +02:00
Edward Hervey
ddacbb7793 mpegtsdemux: Ensure we always get an upstream stream-id
This was a regression.

We only have a upstream-id via STREAM_START if we were in push-mode.
In pull-mode we need to create one.

Note: It would be good to eventually have that method (copied from
gst_pad_get_stream_id_internal()) public in the future
2016-10-12 14:35:21 +02:00
Edward Hervey
ee70f830a8 mpegtsdemux: Fix issues with GST_DISABLE_GST_DEBUG
Some variables were hidden or unused
2016-10-11 16:47:37 +02:00
Edward Hervey
bcc06d679a mpegtsdemux: Switch to using GstStream/GstStreamCollection
For each MpegTSBaseStream, we have a GstStream object which
subclasses can extend with information.

For each program a GstStreamCollection is created with all
GstStream from each stream.
2016-10-11 12:38:02 +02:00
Edward Hervey
dc703b50b3 mpegtsbase: Remove duplicated code
Just have one function to check for private section streams
2016-10-11 12:37:57 +02:00
Edward Hervey
fb36608ccd mpegts: Also clear packetizer on TIME DISCONT
When dealing with TIME-based input, the incoming stream could have
potentially changed completely.

In order to check whether it did or not, we need to re-check all sections
(PAT, PMT...). If it didn't, we will keep using the existing streams/pad,
and if it did we will act as if there was a program switch.

Fixes HLS streaming with decodebin3/playbin3
2016-10-08 14:14:00 +02:00
Wonchul Lee
69b866326e tsdemux: Add conditions to identify ATSC EAC3
https://bugzilla.gnome.org/show_bug.cgi?id=770528
2016-10-03 15:14:54 -04:00
Kyungyong Kim
214a041e13 h265parse: Fix parsing of multiple NALs in the hvcC box
https://bugzilla.gnome.org/show_bug.cgi?id=771970
2016-09-26 09:35:25 +03:00
Sebastian Dröge
8daf628910 jpeg2000parse: Don't pass NULL strings to the colorspace / sampling parsing functions
They assert on NULL.
2016-09-24 10:05:49 -04:00
Joakim Johansson
2837ca997f rtponviftimestamp: Change default value of D-bit
The default value of D-bit is changed to TRUE so discontinuity
is set for initial request and seek request as well.

Only set the e_bit flag for the CUSTOM_DOWNSTREAM event if
a cached buffer exists.

https://bugzilla.gnome.org/show_bug.cgi?id=770221
2016-09-19 11:24:47 -04:00
Hyunjun Ko
4ba54b6046 dvbsuboverlay: map with READWRITE for overlay blend
Just as in basetextoverlay [1], the frame to blend with the subtitles overlay
should be mapped with flags GST_MAP_READWRITE, because
gst_video_overlay_composition_blend() does both operations.

1. https://cgit.freedesktop.org/gstreamer/gst-plugins-base/commit/?id=1396f804

Signed-off-by: Víctor Manuel Jáquez Leal <vjaquez@igalia.com>

https://bugzilla.gnome.org/show_bug.cgi?id=771382
2016-09-14 10:55:09 +02:00
Graham Leggett
7713bb763e tsdemux: handle a NULL name in DVB short event descriptor
Resolves the warning:

GStreamer-WARNING **: Trying to set NULL string on field 'title' on taglist.

https://bugzilla.gnome.org/show_bug.cgi?id=771198
2016-09-13 12:23:28 +01:00
Wonchul Lee
35d147930d tsdemux: Support ATSC EAC3
EAC3 bit streams shall be identified with a stream_type value of 0x87 when
transmitted as PES streams conforming to ATSC-published standards. It is specified
in ATSC Standard A/52.

https://bugzilla.gnome.org/show_bug.cgi?id=770528
2016-09-01 17:56:41 -04:00
Thibault Saunier
2fb716409c Use the new API to post flow ERROR messages on the bus
https://bugzilla.gnome.org/show_bug.cgi?id=770158
2016-08-26 19:23:31 -03:00
Thibault Saunier
50473d77cc meson: Make mpegts lib build when using subprojects
The headers passed as parametter are relative to the build dir
basically "../subproject/gst-plugins-bad/gst-libs/gst/mpegts/XXX.h"
but that does not match what is needed at build time when building as
subproject, also we always add current dir as include_dir so we are
safe including directly.

And link mpegtsdemux against the 'math' library as it is needed.
2016-08-25 15:17:17 -03:00
Nirbheek Chauhan
42af2d66d8 Add support for Meson as alternative/parallel build system
https://github.com/mesonbuild/meson

With contributions from:

Tim-Philipp Müller <tim@centricular.com>
Matej Knopp <matej.knopp@gmail.com>
Jussi Pakkanen <jpakkane@gmail.com> (original port)

Highlights of the features provided are:
* Faster builds on Linux (~40-50% faster)
* The ability to build with MSVC on Windows
* Generate Visual Studio project files
* Generate XCode project files
* Much faster builds on Windows (on-par with Linux)
* Seriously fast configure and building on embedded

... and many more. For more details see:

http://blog.nirbheek.in/2016/05/gstreamer-and-meson-new-hope.html
http://blog.nirbheek.in/2016/07/building-and-developing-gstreamer-using.html

Building with Meson should work on both Linux and Windows, but may
need a few more tweaks on other operating systems.
2016-08-20 11:35:54 +01:00
Nirbheek Chauhan
7e2b68fe2f plugins: Use stdint.h instead of _stdint.h
_stdint.h is generated by Autotools and we don't really need it. All
supported platforms now ship with stdint.h. The only stickler was MSVC,
and since Visual Studio 2015 it also ships stdint.h now.
2016-08-19 14:42:52 +01:00
Luis de Bethencourt
9514d06ab6 rawvideoparse: fix typo in comment
Small typo in the comment explaining the code fixed by the previous commit.
Fixing it.
2016-08-19 12:25:48 +01:00
Sebastian Dröge
a27103b536 rawvideoparse: Revert last commit and actually remember the physically last plane
Instead of just always taking the last one as before.
2016-08-19 14:19:38 +03:00
Luis de Bethencourt
94c5e998c2 rawvideoparse: remove unused assignment
Value in last_plane will be overwritten before used, remove unused
asignment.

Fixes commit 91cf5ac69f
CID 1371462
2016-08-19 11:57:35 +01:00
Carlos Rafael Giani
91cf5ac69f rawvideoparse: Compute plane offsets & strides if no custom ones are set
This is useful to ensure that the offsets and strides are computed if
only width, height, format etc. in the property config are set.

https://bugzilla.gnome.org/show_bug.cgi?id=769797
2016-08-18 09:21:16 +03:00
xlazom00
94d11f87c7 hls, timecode: fix linking
https://bugzilla.gnome.org//show_bug.cgi?id=769587
2016-08-07 16:45:25 +01:00
Bernhard Miller
9171fa9c19 aiffparse: keep end_offset when seeking
After seeking in aiff files the information about the data end offset is
discarded, leading to audio artifacts with metadata chunks at the end of
a file.
This patch retains the end offset information after a seek event.

https://bugzilla.gnome.org//show_bug.cgi?id=769376
2016-08-06 16:47:27 +01:00
Tim-Philipp Müller
f991e09319 dvdspu: don't crash if video frame could not be mapped
As might happen with e.g. vaapi and the test file from
https://bugzilla.gnome.org/show_bug.cgi?id=736227
2016-08-06 16:17:06 +01:00
Vivia Nikolaidou
3072dd80d2 timecodewait: New element to wait for a specific timecode
timecodewait receives a timecode as an argument (either as string or as
GstVideoTimeCode - one is gst-launch-friendly and the other is code-friendly),
and it will drop all audio and video buffers until that timecode has been
reached.

https://bugzilla.gnome.org/show_bug.cgi?id=766419
2016-08-04 19:08:27 +03:00
Vivia Nikolaidou
a2c6e2b64a timecodestamper: New element to attach SMPTE timecode to buffers
The timecodestamper element attaches a SMPTE timecode to each video buffer.
This timecode corresponds to the current stream time.

https://bugzilla.gnome.org/show_bug.cgi?id=766419
2016-08-04 19:08:27 +03:00
Edward Hervey
51c5ff45de tsdemux: Fix draining on wrong programs
When draining a program, we might send a newsegment event on the pads
that are going to be removed (and then the pending data).

In order to do that, calculate_and_push_newsegment() needs to know
what list of streams it should take into account (instead of blindly
using the current one).

All callers to calculate_and_push_newsegment() and push_pending_data()
can now specify the program on which to act (or NULL for the default
one).
2016-08-03 17:15:41 +02:00
Edward Hervey
e2b98a7721 tsdemux: Fix GAP synchronization without a valid PCR PID
For streams that don't have a valid PCR PID, we just use the latest
PTS from any given stream.

https://bugzilla.gnome.org/show_bug.cgi?id=608148
2016-08-03 17:15:41 +02:00
Michael Olbrich
36e6590335 tsdemux: handle pcr_pid == 0x1fff
Streams without PCR make senses in HLS, where the playlist timestamps
can be used to seek or calculate the duration.

https://bugzilla.gnome.org/show_bug.cgi?id=608148
2016-08-03 17:15:41 +02:00
Arnaud Vrac
7a3d189250 mpegtsdemux: do not abort playback when no PCR were found during initial scan
Seeking will not be possible in those streams but at least the can be
played. Note scanning is only done when tsdemux is configured in pull mode.

https://bugzilla.gnome.org/show_bug.cgi?id=608148
2016-08-03 17:15:41 +02:00