A return value of FALSE here indicates that we don't have control-values. In
0.10 we were returning the default value of the property. Now we don't fill an
array with defaults in the ControlBinding, but leave it up to the element to
handle this case.
The codec data blob we get from matroskademux with the SSA/ASS
init section is supposed to be valid UTF-8. If it's not, just
continue with the bits that are valid UTF-8 instead of erroring
out. We don't actually parse the init section yet anyway..
https://bugzilla.gnome.org/show_bug.cgi?id=607630
The behaviour is sensibly changed here. Instead of purely falling when a
preset is set on the #GstEncodingProfile, we now make sure that the
element that is plugged corresponds to the one specified as preset. Then,
if we have a preset_name, we use it, if it fails, we fail (we might rather
just keep working even without setting the element properties?)
+ Add tests that it behave correctly
When the input buffers for a stream don't have a duration set,
timestamp_end might still be GST_CLOCK_TIME_NONE. When advancing
EOSed streams via GAP events (with other streams not yet EOS), we
would then use the invalid timestamp_end to calculate the duration
of the gap. This in turn would make baseaudiosink abort, because it
would try to allocate memory for a trizillion samples.
So if buffers don't have a duration set, assume a duration of
one second for stream catch-up purposes, just so we can still
continue to catch up in those cases. And make sure that
timestamp_end is valid before doing calculations with it.
http://bugzilla.gnome.org/show_bug.cgi?id=678530
Make AAC LOAS typefinding a bit more reliable; don't report
a LIKELY probability already after just two sync points, but
scan for a few more consecutive frames and determine probability
based on how many we found. Fixes mis-detection of wavpack file.
https://bugzilla.gnome.org/show_bug.cgi?id=687674
Check for second block sync and return different
probabilities depending on what we found (trumping
the AAC loas typefinder's LIKELY probability after
finding a second frame sync in this particular case).
https://bugzilla.gnome.org/show_bug.cgi?id=687674
Previously we could've chosen another format with the same
depth even if the input format was possible.
Also make sure to chose according to the order in the
caps.
Enhance current code to prefer an exact match on sample depth if
possible. Also ignore GST_AUDIO_FORMAT_FLAG_UNPACK when checking
equality on the flags.
This is an adaptation of patch #3 from Jyri Sarha
( http://lists.xiph.org/pipermail/speex-dev/2011-September/008240.html ),
but without the NEON optimizations (these come in a separate commit).
The idea is to replace SATURATE32(PSHR32(x, shift), a) operations with a
combined SATURATE32PSHR(x, shift, a) macro that can be optimized for
specific platforms (and also avoids rare rounding errors).
Signed-off-by: Carlos Rafael Giani <dv@pseudoterminal.org>
There were two issues with the previous decodebin2 group switching algorithm:
Issue 1: It operated with no memory of what has been drained or not, leading to
multiple checks for chains/groups that were already drained.
Issue 2: When receiving an EOS, it only detected that a higher-level chain
was drained if it contained the pad receiving the EOS.
The following modifications have been applied:
- a new drained property has been added to GstDecodeChain
- both drained properties of chain/group are set as soon as they are detected
- the algorithm now tests agains these values
See https://bugzilla.gnome.org/show_bug.cgi?id=685938
Should fix "cannot register existing type `GstPlaybinSelectorPad'" warnings
and subsequent errors when creating multiple players at the same time.
Conflicts:
gst/playback/gststreamselector.c
GstId3Mux sink pad is an always (static) pad. Thus releasing it
as if a request pad triggers:
(sound-juicer:11826): GStreamer-CRITICAL **:
gst_element_release_request_pad: assertion `GST_PAD_PAD_TEMPLATE (pad)
== NULL || GST_PAD_TEMPLATE_PRESENCE (GST_PAD_PAD_TEMPLATE (pad)) ==
GST_PAD_REQUEST' failed
https://bugzilla.gnome.org/show_bug.cgi?id=685110
Need to store the old running time and frame numbers when renegotiating and
start from 0 again when a new caps is set, preventing that framerate changes
cause timestamping issues.
For example, if a stream pushed 10 buffers on framerate=2/1, its
running time will be 5s. If a new framerate of 1/1 is set, it would
make the running time go to 10s as it would count those 10 buffers
as being sent on this new framerate.
Fixes camerbin unit test.
https://bugzilla.gnome.org/show_bug.cgi?id=682973
../../../gst-plugins-base/gst/audioresample/gstaudioresample.c: In function 'gst_audio_resample_dump_drain':
../../../gst-plugins-base/gst/audioresample/gstaudioresample.c:729:9: warning: variable 'in_len' set but not used [-Wunused-but-set-variable]
streams with non-TIME segments will not have timestamps ...
... and therefore will never unblock the other streams.
Fixes blocking issue when using playbin suburi feature
People expect audiorate to fix things up and not make things worse
by default, so let's default to a similar tolerance as audiosinks
do. Should help with transcoding and the like, though one might
possible still want higher values then.
We can't just make a vfunc that takes a union of int
and pointer as argument, and then set up subclass-specific
action signals and signals that take int (in multifdsink's
case) or a GSocket * (in multisocketsink's case), and then
expect everything to Just Work. This blows up spectacularly
on PPC G4 for some reason.
Fixes multifdsink unit test on PPC, and fixes aborts in
multisocketunit test (now hangs in gst_pad_push - progress).
* Update outgoing segment.base with accumulated time, ensuring all
streams are synchronized.
* Only consider streams as "new" is they have a STREAM_START event
with a different seqnum.
* Use GstStream segment.base instead of separate variable to store
the past running time.
* Disable passthrough
* Switch to glib 2.32 GMutex/GCond
* Avoid getting pad parent the expensive way
* Minor other fixes
Make sure to send a CAPS event downstream when we get our
first input caps. This fixes not-negotiated errors and
adder use with downstream elements other than fakesink.
Even gst-launch-1.0 audiotestsrc ! adder ! pulsesink works now.
Also, flag the other sink pads as FIXED_CAPS when we receive
the first CAPS event on one of the sink pads (in addition to
setting those caps on the the sink pads), so that a caps query
will just return the fixed caps from now on.
There's still a race between other upstreams checking if
caps are accepted and sending a first buffer with possibly
different caps than the first caps we receive on some other
pad, but such is life.
Also need to take into account optional fields better/properly.
https://bugzilla.gnome.org/show_bug.cgi?id=679545
Fix invalid memory access caused by broken pointer arithmetic.
If we have a uint16_t *tmpbuf and add n * dest->stride to it, we
skip twice as much as we intended to because dest->stride is in
bytes and not in pixels. This made us write beyond the end of
our allocated temp buffer, and made the unit test crash.
Make function pointers NULL when nothing needs to be done.
Pass target pixels to dither and matrix functions so that we can later make
them operate on the target buffer memory directly.
This allows the following use-cases to expose the group and pads
before an ALLOCATION query comes through:
* Single stream use-cases
* Multi stream use-cases where all streams sent the CAPS event before
the first ALLOCATION query
Some cases will still make the initial ALLOCATION query fail though,
which isn't optimal, but not fatal (it will recover when pads are
exposed, a RECONFIGURE event is sent upstream and elements can
re-send an ALLOCATION query which will reach downstream elements).
https://bugzilla.gnome.org/show_bug.cgi?id=680262
A caps event is also used to establish that a stream has prerolled.
Without this, we end up allowing negotiation queries to fail, ending
in decoders (and other elements) to not be configured right from the
start with the most optimal settings.
videoconvert.c: In function 'videoconvert_convert_new':
videoconvert.c:287:11: error: 'Kr' may be used uninitialized in this function
videoconvert.c:287:15: error: 'Kb' may be used uninitialized in this function
Fix the calculation of the offset and scale values for GRAY formats. We also
need to set the offset and base of the chroma values to match what the unpack
function creates.
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=679612
Might just be paranoia, but better safe than sorry. Make sure
the compiler really always passes a 64-bit integer to the
g_object_set() vararg function.
They are not added again by every code path, e.g. when switching
only the deinterlace flag and are missing then.
Fixes bug #678763.
Conflicts:
gst/playback/gstplaysink.c
...and in playbin2 additionally prefer sinks over parsers.
This makes sure that we a) always directly plug a sink if it supports
the (compressed) format and b) always plug parsers in front of decoders.
This avoids that bin being leftover and being found when reusing playbin2,
and fixes restarting on a new URI after failing to activate with a previous
URI.
https://bugzilla.gnome.org/show_bug.cgi?id=673888
For audio/video we should flush too for fastest stream switches but this
currently isn't possible because the flushes would need to go to the sink,
which then causes state changes and causes all timing information to be
changed.
Should work out of the box in 0.11 with the flush-stop that doesn't reset
the times.
Conflicts:
gst/playback/gstplaybin2.c
gst/playback/gstplaysink.c
gst/playback/gstsubtitleoverlay.c
Sending a non-flushing seek might not be enough for switching
to an external sub that has already been used because the flushes
are needed to reset the state of its decodebin's queue.
For example, if the subtitle is short enough, the queue might get
and EOS and keep its 'unexpected' return state. If the user switches
to another subtitle and back to the external one, the buffers
won't get past the queue.
This patch fixes this by adding the flush flag to the seek and
preventing that this flush leaves the suburidecodebin.
https://bugzilla.gnome.org/show_bug.cgi?id=638168
Conflicts:
gst/playback/gstplaybin2.c
RGB8_PALETTED -> RGB8P
Fix the definition of paletted formats, store the palette in the second
plane.
Make sure we copy the palette correctly in gst_video_frame_copy()
Don't do alignment on the palette in videopool
Add support for the I420_10 formats
Use the video frame api to get pixels and strides instead of our own
custom versions. Fixes the YVU9 format and probably some others.
Make the uri property getter return the next uri, like it was configured in the
setter.
Make a new current-uri and current-suburi property that reflects the currently
playing uri and suburi.
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=676665
This makes sure that we always prefer sinks that support a format without
decoding, independant of its rank. Previously we only sorted by rank.
Conflicts:
gst/playback/gstplaybin2.c
If a property is not found (for example last-sample when
gst_debug_bin_to_dot_file is used while the pipeline is
slightly broken (thus no last-sample) the unref of the item
gvalue which is not refed fails. Only unref if it was found.
They're hardly used, and probably more confusing than anything
else, and it's not clear that anyone would really need to be
able to tell them apart at the media type level.
The sinkpads are unblocked when going from PAUSED->READY, we need to block them
again when going READY->PAUSED. The blocking of the pad previously only happened
when it was freshly obtained with _request_pad or when the caps changed. If we
don't release the pad when going to READY it was previously never blocked again
causing not-linked errors.
For example the Sintel subtitles have this and without this change
they're detected as text/plain and not usable as subtitles. The
parser itself already handles this just fine.
For streaming sources a queue is added before the demuxer, which can not be
properly filled by live sources. As http source can be live sources, this
caused issues for example with http live sources.
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=674057
Adds a property for playsink to define how it should handle
events sent in send_event function. The default is the same as
GstBin's, sending events to all internal sinks. There is also
mode-first, that will send to sinks until the one handles the
event successfully.
https://bugzilla.gnome.org/show_bug.cgi?id=673211
When the video sink is a fakesink, which does not implement the
navigation interface, playsink will drop the navigation command.
In this case, send to the video sink as a fallback. It breaks
the interface abstraction, but is better than just dropping the
navigation event.