Brad Hards
49d8921232
qtdemux: fix version 1 profile handling, add diagnostics
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8456 >
2025-02-14 00:03:30 +00:00
Brad Hards
c7367addb5
qtdemux: support uncompressed mono with component interleave
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8464 >
2025-02-13 08:17:17 +00:00
Carlos Bentzen
e2bd8809bf
qtmux: add support for VVC/H.266 video
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8436 >
2025-02-11 03:25:38 +00:00
Carlos Bentzen
a5c6eea957
qtdemux: add support for VVC/H.266
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5088 >
2025-02-10 09:20:22 +00:00
dukesook
54830e7c0a
qtdemux: Demux Uncompressed MP4
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7985 >
2025-02-08 10:15:06 +00:00
Robert Mader
1fc6f0d349
qtmux: Implement rotation tag support
...
Mirroring the demux element and isomp4mux from gst-plugins-rs.
Tested against other Gst elements and MPV. Note that the later
apparently does not show correct results for flipped values.
Can be tested with:
```
gst-launch-1.0 \
videotestsrc num-buffers=90 ! \
taginject tags="image-orientation=rotate-90" ! \
capsfilter caps=video/x-raw,width=640,height=480,max-framerate=30/1 ! \
videoconvert ! \
queue ! \
openh264enc ! \
queue ! \
h264parse ! \
mp4mux ! \
filesink location=./test.mp4
```
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8371 >
2025-01-29 16:24:21 +00:00
Alexander Slobodeniuk
6376849396
qtmux: fix critical warnings on negotiation error
...
This pipeline fails to negotiate on my PC:
gst-launch-1.0 v4l2src ! h264parse ! qtmux ! filesink location=t.mp4
When it happens some critical glib warnings are emitted:
-------------------------------
GStreamer-CRITICAL **: 15:09:03.485: gst_mini_object_copy: assertion 'mini_object != NULL' failed
GStreamer-CRITICAL **: 15:09:03.485: gst_mini_object_unref: assertion 'mini_object != NULL' failed
GStreamer-CRITICAL **: 15:09:03.485: gst_caps_get_structure: assertion 'GST_IS_CAPS (caps)' failed
GStreamer-CRITICAL **: 15:09:03.485: gst_structure_set_value: assertion 'structure != NULL' failed
GStreamer-CRITICAL **: 15:09:03.485: gst_mini_object_unref: assertion 'mini_object != NULL' failed
--------------------------------
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8374 >
2025-01-29 10:46:25 +00:00
Mathieu Duponchelle
3de86b2b97
docs: port plugins to explicit sources
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8273 >
2025-01-13 19:17:13 +01:00
Edward Hervey
8bc17b58a2
good: Clearly specify fallthrough in switch/case
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8229 >
2025-01-13 12:51:45 +00:00
Edward Hervey
5d69f2bc36
qtmux: Fix GST_STIME_ARGS usage
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8229 >
2025-01-13 12:51:45 +00:00
Christian Meissl
422fca76ca
qtdemux: fix accumulated base offset in segment seeks
...
analog to fix for matroska-demux
commit f3c126d07c
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8240 >
2025-01-06 09:44:00 +00:00
Sebastian Dröge
0aeba9275c
qtdemux: Add support for ISO/IEC 23003-5 raw PCM audio
...
And also support the ISO/IEC 14496-12 chnl channel layout box as required
by ISO/IEC 23003-5.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8171 >
2025-01-03 10:11:31 +00:00
Jochen Henneberg
68cdeeb882
qtdemux: Undef helper macros after use
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8127 >
2025-01-02 15:22:47 +00:00
Jochen Henneberg
d86f60ffdf
qtdemux: Validate matrix before doing simplified multiply
...
The matrix multiplication makes some assumption about the element
values to simplify the math with fixpoint values. If this is allowed
for the given matrices is now checked first.
Then the debug output for matrix and a comment have been fixed.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8127 >
2025-01-02 15:22:47 +00:00
Jochen Henneberg
5c005733ea
qtdemux: Fixup for orientation matrix parsing
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8127 >
2025-01-02 15:22:47 +00:00
Jochen Henneberg
c4d0f4bbd9
qtdemux: Use mvhd transform matrix and support for flipping
...
The mvhd matrix is now combined with the tkhd matrix. The combined
matrix is then checked if it matches one of the standard values for
GST_TAG_IMAGE_ORIENTATION.
This check now includes matrices with flipping.
Fixes #4064
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8127 >
2025-01-02 15:22:47 +00:00
Sebastian Dröge
519d86d9f3
qtdemux: Add size check for parsing SMI / SEQH atom
...
Thanks to Antonio Morales for finding and reporting the issue.
Fixes GHSL-2024-244
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3853
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8059 >
2024-12-03 21:01:41 +00:00
Sebastian Dröge
bfebca8307
qtdemux: Check for invalid atom length when extracting Closed Caption data
...
Thanks to Antonio Morales for finding and reporting the issue.
Fixes GHSL-2024-243
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3849
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8059 >
2024-12-03 21:01:41 +00:00
Sebastian Dröge
7d3f221d87
qtdemux: Actually handle errors returns from various functions instead of ignoring them
...
Ignoring them might cause the element to continue as if all is fine despite the
internal state being inconsistent. This can lead to all kinds of follow-up
issues, including memory safety issues.
Thanks to Antonio Morales for finding and reporting the issue.
Fixes GHSL-2024-245
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3847
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8059 >
2024-12-03 21:01:41 +00:00
Sebastian Dröge
19359e2b25
qtdemux: Make sure there are enough offsets to read when parsing samples
...
While this specific case is also caught when initializing co_chunk, the error
is ignored in various places and calling into the function would lead to out of
bounds reads if the error message doesn't cause the pipeline to be shut down
fast enough.
To avoid this, no matter what, make sure enough offsets are available when
parsing them. While this is potentially slower, the same is already done in the
non-chunks_are_samples case.
Thanks to Antonio Morales for finding and reporting the issue.
Fixes GHSL-2024-245
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3847
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8059 >
2024-12-03 21:01:41 +00:00
Sebastian Dröge
4a0e8bf92b
qtdemux: Fix error handling when parsing cenc sample groups fails
...
Thanks to Antonio Morales for finding and reporting the issue.
Fixes GHSL-2024-238, GHSL-2024-239, GHSL-2024-240
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3846
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8059 >
2024-12-03 21:01:41 +00:00
Sebastian Dröge
98f3934c48
qtdemux: Fix length checks and offsets in stsd entry parsing
...
Thanks to Antonio Morales for finding and reporting the issue.
Fixes GHSL-2024-242
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3845
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8059 >
2024-12-03 21:01:41 +00:00
Sebastian Dröge
c1cd838706
qtdemux: Make sure enough data is available before reading wave header node
...
Thanks to Antonio Morales for finding and reporting the issue.
Fixes GHSL-2024-236
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3843
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8059 >
2024-12-03 21:01:41 +00:00
Sebastian Dröge
1d534ac209
qtdemux: Make sure only an even number of bytes is processed when handling CEA608 data
...
An odd number of bytes would lead to out of bound reads and writes, and doesn't
make any sense as CEA608 comes in byte pairs.
Strip off any leftover bytes and assume everything before that is valid.
Thanks to Antonio Morales for finding and reporting the issue.
Fixes GHSL-2024-195
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3841
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8059 >
2024-12-03 21:01:41 +00:00
Sebastian Dröge
5a9e80c01b
qtdemux: Check sizes of stsc/stco/stts before trying to merge entries
...
Thanks to Antonio Morales for finding and reporting the issue.
Fixes GHSL-2024-246
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3854
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8059 >
2024-12-03 21:01:41 +00:00
Sebastian Dröge
0f4dae9b01
qtdemux: Don't iterate over all trun entries if none of the flags are set
...
Nothing would be printed anyway.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8059 >
2024-12-03 21:01:41 +00:00
Sebastian Dröge
cbd659c58f
qtdemux: Fix debug output during trun parsing
...
Various integers are unsigned so print them as such. Also print the actual
allocation size if allocation fails, not only parts of it.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8059 >
2024-12-03 21:01:41 +00:00
Antonio Morales
ae61a604c0
qtdemux: Fix integer overflow when allocating the samples table for fragmented MP4
...
This can lead to out of bounds writes and NULL pointer dereferences.
Fixes GHSL-2024-094, GHSL-2024-237, GHSL-2024-241
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3839
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8059 >
2024-12-03 21:01:41 +00:00
Sebastian Dröge
f8e398c46f
qtdemux: Avoid integer overflow when parsing Theora extension
...
Thanks to Antonio Morales for finding and reporting the issue.
Fixes GHSL-2024-166
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3851
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8032 >
2024-12-03 02:24:16 +00:00
Dean Zhang (张安迪)
a7f35d4f3c
qtdemux: Add support for m1v fourcc when subtype is vide
...
Some special videos with mlv fourcc can't be recognized by
qtdemux when the subtype of the video is vide instead of
m1v, and will cause negotiation error in subsequent plugin.
So make the handle in qtdemux_video_caps. It might be better
than nothing.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7855 >
2024-11-11 12:04:04 +00:00
Andoni Morales Alastruey
15c990a8d8
qtdemux: fix parsing of matrix with 180 rotation
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7607 >
2024-10-14 16:54:38 +00:00
valadaptive
b923a3ed61
qtdemux: Add support for Lagarith fourcc tag
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6831 >
2024-10-10 03:55:04 +00:00
Sebastian Dröge
bbd3d6f4f6
qtdemux: Check fourcc of a second CEA608 atom instead of assuming it's cdt2
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7575 >
2024-09-29 06:18:56 +00:00
Sebastian Dröge
6233eb0ff3
common: Stop using GQuark-based GstStructure field name API
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7432 >
2024-09-26 19:21:29 +03:00
Sebastian Dröge
d4bab55077
qtdemux: Skip zero-sized boxes instead of stopping to look at further boxes
...
A zero-sized box is not really a problem and can be skipped to look at any
possibly following ones.
BMD ATEM devices specifically write a zero-sized bmdc box in the sample
description, followed by the avcC box in case of h264. Previously the avcC box
would simply not be read at all and the file would be unplayable.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7564 >
2024-09-24 11:21:19 +03:00
Seungha Yang
fd21d97060
qtdemux: Handle keyunit trick mode in case of push mode too
...
Skip non-keyframe video frames if trickmode-keyunit flag is set
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5900 >
2024-05-31 11:21:55 +00:00
Seungha Yang
05f9eadcaf
qtmux: Handle time information value > UINT32_MAX
...
If any duration in timescale is larger than UINT32_MAX, use version 1
atom, otherwise file header will be constructed with truncated values.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6843 >
2024-05-28 16:09:58 +00:00
Qian Hu (胡骞)
cd95d02032
qtdemux: fix wrong full_range offset when parsing colr box
...
use colr_data[18] >> 7 to get full range information, instead
of colr_data[17] >> 7
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6616 >
2024-04-12 16:59:33 +08:00
Piotr Brzeziński
9c084faa75
qtdemux: Fix wrapping temporary memory in buffers
...
That memory can disappear at any moment, doesn't cost much to just copy those few bytes.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6320 >
2024-03-11 18:18:01 +00:00
Elizabeth Figura
e2167867d5
qtdemux: Do not set channel-mask to zero
...
Leave it uninitialized, so that the downstream decoder will initialize it appropriately. Setting it to zero is wrong.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6225 >
2024-03-07 12:52:30 +02:00
Jochen Henneberg
6608b89977
rtpxqtdepay: Enabled header extension aggregation
...
Because this depayloader may build several output buffers within one
process run we push them all into a GstBufferList and push them out at
once to make sure that each buffer gets notified about each header
extension.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5378 >
2024-02-19 11:23:17 +00:00
Philippe Normand
30bb88a91b
qtdemux: Basic support for container-specific-track-id tag
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6041 >
2024-02-12 10:37:29 +00:00
Thibault Saunier
77e7efe407
qtdemux: Lower verbosity of some often happenning warnings
...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6011 >
2024-01-30 09:09:22 +00:00
Guillaume Desmottes
a56923d5e6
qtdemux: fix bug report URL
...
Using PACKAGE_BUGREPORT as in other modules.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5762 >
2023-12-05 09:25:22 +01:00
Thibault Saunier
14c7d3f4e9
qtdemux: Do not update demux->offset
when droping data on EOS
...
The offset is updated right after and we were breaking it by updating it
twice.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5724 >
2023-12-02 08:08:26 +00:00
Thibault Saunier
b1b29de0fb
qtdemux: Do not mark stream as EOS only if all streams are EOS
...
The `GstFlowCombiner` is responsible for tracking the flow of each
stream and handle the overal flow return value. Without that, we
can end up with the following scenario:
- Audio+video stream
- Only the video stream is linked downstream
- The audio stream goes EOS, video doesn't yet
-> We update the Flow in the combiner with OK as all streams are not EOS
- Video goes EOS because downstream returned EOS
-> `qtdemux` returns `FLOW_OK` forever because the unlinked audio pad
has `last_flowret==FLOW_OK`
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5724 >
2023-12-02 08:08:26 +00:00
Thibault Saunier
8295b2ae5c
qtdemux: Determine EOS based on the stream segment
...
Depending on the stream segment might vary (because of edts for example)
leading to EOS being sent at the wrong time (too early for example).
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5724 >
2023-12-02 08:08:26 +00:00
Hosang Lee
7bf646e5ba
qtdemux: Don't overflow sample index
...
Don't reduce sample index if it is already at 0.
Assigning -1 to a guint32 variable causes unexpected behavior.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5743 >
2023-12-01 13:34:12 +00:00
Hosang Lee
041e0c6cab
qtdemux: Fix reverse playback for pcm audio stream
...
Some raw lpcm or adpcm may have larger sample sizes than the max
buffer size value set.
Trimming the buffer causes bogus size error on reverse playback.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5742 >
2023-12-01 15:11:04 +09:00
Piotr Brzeziński
4037334143
qtdemux: Ignore raw audio streams when adjusting seek
...
Because we treat raw audio chunks/samples as keyframes, they were interfering
with seek time adjustment.
Became apparent when the accompanying video stream was I-frame only,
for example ProRes.
Since raw audio streams can be seeked freely, it's fine to just ignore them here,
giving priority to the real keyframes in the video stream.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4946 >
2023-11-15 07:55:27 +00:00