gst-plugins-good issueshttps://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues2023-10-12T16:02:53Zhttps://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1021Internal Data Stream Error Occurs When Adding Two Caps Filters with Different...2023-10-12T16:02:53ZSulthan AmanuInternal Data Stream Error Occurs When Adding Two Caps Filters with Different Resolutions in Webcam GStreamer Pipeline Using TeeI have encountered an issue while creating a GStreamer pipeline with a webcam source and two caps filters using the tee element. The pipeline is designed to apply different resolutions to the video stream. Below is an example of the pipe...I have encountered an issue while creating a GStreamer pipeline with a webcam source and two caps filters using the tee element. The pipeline is designed to apply different resolutions to the video stream. Below is an example of the pipeline:
gst-launch-1.0 -e v4l2src device=/dev/video0 ! \
tee name=t ! \
queue ! \
videoconvert ! \
capsfilter caps="video/x-raw, width=640, height=480" ! \
autovideosink t. ! \
queue ! \
videoconvert ! \
capsfilter caps="video/x-raw, width=1280, height=720" ! \
autovideosink
However, when executing the pipeline, I encountered the following error message:
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Internal data stream error.
Additional debug info:
gstbasesrc.c(3055): gst_base_src_loop (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
streaming stopped, reason not-negotiated (-4)
EOS on shutdown enabled -- waiting for EOS after Error
Waiting for EOS...
I kindly request your assistance in resolving this issue and achieving the desired behavior without utilizing the **videoscale** element.https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1020Inconsistency in spectrum element message (multi threaded environment)2023-07-05T06:38:01ZSrinivas SaladiInconsistency in spectrum element message (multi threaded environment)Spectrum magnitude messages posted on bus are not consistent when invoked by multiple threads
For the same clip, I am getting different values when multiple threads invoking a simple pipeline application having spectrum element
(0.10.6) ...Spectrum magnitude messages posted on bus are not consistent when invoked by multiple threads
For the same clip, I am getting different values when multiple threads invoking a simple pipeline application having spectrum element
(0.10.6) versionhttps://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1019Wrong redirection on rtspsrc2023-06-30T11:35:23ZDmitry ParfenovWrong redirection on rtspsrcWhen rtspsrc gets 302 code (redirect) to another port, it takes new endpoint but tries to send it to the same port, ignoring the new port in the given link
Process below:
First request:
![image](/uploads/54538cf047c4691e0e474dbf30dcd4ee...When rtspsrc gets 302 code (redirect) to another port, it takes new endpoint but tries to send it to the same port, ignoring the new port in the given link
Process below:
First request:
![image](/uploads/54538cf047c4691e0e474dbf30dcd4ee/image.png)
Redirect response:
![image](/uploads/7a17e740fdf81adddb4a86e2cf2830e5/image.png)
Resending DESCRIBE, but Dst port is the same:
![image](/uploads/4c91ab32108b0f3e87e6656e644b075f/image.png)
It is of course creates error and connection does not happen
Version: 1.16.3https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1018Scaletempo 2x playback causes high CPU loading2023-06-26T10:05:55ZrlandjScaletempo 2x playback causes high CPU loadingOn an Android phone that I use on a daily basis (running Android O),
I have found that when playing at 2x speed, the CPU loading of the
entire GStreamer pipeline is relatively high, sometimes reaching around 60% cpu loading.
I used sim...On an Android phone that I use on a daily basis (running Android O),
I have found that when playing at 2x speed, the CPU loading of the
entire GStreamer pipeline is relatively high, sometimes reaching around 60% cpu loading.
I used simpleperf to run a callgraph hot spot map and found that the bottleneck
is in the best_overlap_offset_s16() function in gstscaletempo.c,almost 98% CPU loading is consumed by this function. Therefore, I came here to seek help from the knowledgeable experts on this forum. Is anyone familiar with NEON programming? Can you help me optimize this function using the SIMP instruction in NEON? I have no prior experience with NEON, but I do have a mobile device handy that I can use to compare the performance before and after optimization.
```
Arch: arm64
Event: cpu-cycles:u (type 0, config 0)
Samples: 30624
Event count: 23246964527
Children Self Command Pid Tid Shared Object Symbol
34.42% 0.00% amcaudiodec-c 17305 17427 /apex/com.android.runtime/lib/bionic/libc.so __start_thread
|
-- __start_thread
|
-- __pthread_start(void*)
g_thread_proxy
g_thread_pool_thread_proxy
gst_task_func
|--0.04%-- [hit in function]
|
--99.96%-- gst_amc_audio_dec_loop
|--0.13%-- [hit in function]
|
|--95.13%-- gst_audio_decoder_finish_frame
| |--0.14%-- [hit in function]
| |
| |--99.21%-- gst_audio_decoder_output
| | |--0.03%-- [hit in function]
| | |
| | --99.97%-- gst_audio_decoder_push_forward
| | |
| | |--99.92%-- gst_pad_push
| | | gst_pad_push_data
| | | |--0.01%-- [hit in function]
| | | |
| | | |--99.93%-- gst_pad_chain_data_unchecked
| | | | |--0.08%-- [hit in function]
| | | | |
| | | | |--99.78%-- gst_proxy_pad_chain_default
| | | | | |--0.08%-- [hit in function]
| | | | | |
| | | | | |--99.87%-- gst_pad_push
| | | | | | |
| | | | | | |--99.95%-- gst_pad_push_data
| | | | | | | |--0.01%-- [hit in function]
| | | | | | | |
| | | | | | | |--99.95%-- gst_pad_chain_data_unchecked
| | | | | | | | |
| | | | | | | | |--99.96%-- gst_proxy_pad_chain_default
| | | | | | | | | gst_pad_push
| | | | | | | | | |--0.02%-- [hit in function]
| | | | | | | | | |
| | | | | | | | | --99.98%-- gst_pad_push_data
| | | | | | | | | |
| | | | | | | | | |--99.89%-- gst_pad_chain_data_unchecked
| | | | | | | | | | |--0.02%-- [hit in function]
| | | | | | | | | | |
| | | | | | | | | | |--99.95%-- gst_concat_sink_chain
| | | | | | | | | | | |
| | | | | | | | | | | |--99.95%-- gst_pad_push
| | | | | | | | | | | | gst_pad_push_data
| | | | | | | | | | | | |
| | | | | | | | | | | | |--99.97%-- gst_pad_chain_data_unchecked
| | | | | | | | | | | | | |--0.02%-- [hit in function]
| | | | | | | | | | | | | |
| | | | | | | | | | | | | |--99.91%-- gst_proxy_pad_chain_default
| | | | | | | | | | | | | | |
| | | | | | | | | | | | | | |--99.92%-- gst_pad_push
| | | | | | | | | | | | | | | gst_pad_push_data
| | | | | | | | | | | | | | | |--0.02%-- [hit in function]
| | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | |--99.97%-- gst_pad_chain_data_unchecked
| | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | |--99.93%-- gst_tee_chain
| | | | | | | | | | | | | | | | | |--0.05%-- [hit in function]
| | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | --99.95%-- gst_tee_handle_data
| | | | | | | | | | | | | | | | | |--0.06%-- [hit in function]
| | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | --99.94%-- gst_pad_push
| | | | | | | | | | | | | | | | | gst_pad_push_data
| | | | | | | | | | | | | | | | | |--0.01%-- [hit in function]
| | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | |--99.93%-- gst_pad_chain_data_unchecked
| | | | | | | | | | | | | | | | | | |--0.02%-- [hit in function]
| | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | |--99.93%-- gst_stream_synchronizer_sink_chain
| | | | | | | | | | | | | | | | | | | |--0.05%-- [hit in function]
| | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | |--99.88%-- gst_pad_push
| | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | |--99.98%-- gst_pad_push_data
| | | | | | | | | | | | | | | | | | | | | |--0.03%-- [hit in function]
| | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | |--99.93%-- gst_pad_chain_data_unchecked
| | | | | | | | | | | | | | | | | | | | | | |--0.02%-- [hit in function]
| | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | |--99.88%-- gst_proxy_pad_chain_default
| | | | | | | | | | | | | | | | | | | | | | | gst_pad_push
| | | | | | | | | | | | | | | | | | | | | | | gst_pad_push_data
| | | | | | | | | | | | | | | | | | | | | | | |--0.03%-- [hit in function]
| | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | |--99.90%-- gst_pad_chain_data_unchecked
| | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | |--99.95%-- gst_base_transform_chain
| | | | | | | | | | | | | | | | | | | | | | | | | |--0.04%-- [hit in function]
| | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | |--99.78%-- gst_pad_push
| | | | | | | | | | | | | | | | | | | | | | | | | | gst_pad_push_data
| | | | | | | | | | | | | | | | | | | | | | | | | | |--0.01%-- [hit in function]
| | | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | | --99.99%-- gst_pad_chain_data_unchecked
| | | | | | | | | | | | | | | | | | | | | | | | | | |--0.02%-- [hit in function]
| | | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | | |--99.95%-- gst_base_transform_chain
| | | | | | | | | | | | | | | | | | | | | | | | | | | |--0.01%-- [hit in function]
| | | | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | |--99.47%-- default_generate_output
| | | | | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | |--99.06%-- gst_scaletempo_transform
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | |--0.18%-- [hit in function]
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | |--98.51%-- best_overlap_offset_s16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | |--0.59%-- fill_queue
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |--6.43%-- [hit in function]
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |--57.72%-- __memcpy_base_a55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |--22.51%-- gst_buffer_map
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | gst_buffer_map_range
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |--26.49%-- [hit in function]
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |--47.69%-- gst_memory_make_mapped
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | gst_memory_map
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |--48.71%-- [hit in function]
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | --51.29%-- gst_mini_object_lock
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | --25.82%-- _get_merged_memory
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | gst_mini_object_ref
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | --13.34%-- gst_buffer_unmap
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |--40.69%-- [hit in function]
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |--40.50%-- gst_mini_object_unlock
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | --18.81%-- gst_memory_unmap
```
```
/* buffer padding for loop optimization: sizeof(gint32) * (loop_size - 1) */
#define UNROLL_PADDING (4*3)
static guint
best_overlap_offset_s16 (GstScaletempo * st)
{
gint32 *pw, *ppc;
gint16 *po, *search_start;
gint64 best_corr = G_MININT64;
guint best_off = 0;
guint off;
glong i;
pw = st->table_window;
po = st->buf_overlap;
po += st->samples_per_frame;
ppc = st->buf_pre_corr;
for (i = st->samples_per_frame; i < st->samples_overlap; i++) {
*ppc++ = (*pw++ * *po++) >> 15;
}
search_start = (gint16 *) st->buf_queue + st->samples_per_frame;
for (off = 0; off < st->frames_search; off++) {
gint64 corr = 0;
gint16 *ps = search_start;
ppc = st->buf_pre_corr;
ppc += st->samples_overlap - st->samples_per_frame;
ps += st->samples_overlap - st->samples_per_frame;
i = -((glong) st->samples_overlap - (glong) st->samples_per_frame);
do {
corr += ppc[i + 0] * ps[i + 0];
corr += ppc[i + 1] * ps[i + 1];
corr += ppc[i + 2] * ps[i + 2];
corr += ppc[i + 3] * ps[i + 3];
i += 4;
} while (i < 0);
if (corr > best_corr) {
best_corr = corr;
best_off = off;
}
search_start += st->samples_per_frame;
}
return best_off * st->bytes_per_frame;
}
```https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1017`Queued GOP time is negative` error in splitmuxsink for rtspsrc2023-06-23T09:12:42ZZiad Hatahet`Queued GOP time is negative` error in splitmuxsink for rtspsrcWe're hitting this error when running a GStreamer pipeline to capture HLS video segments:
```
ERROR: from element /GstPipeline:pipeline0/GstSplitMuxSink:splitmuxsink: Timestamping error on input streams
Additional debug info:
../gst/mul...We're hitting this error when running a GStreamer pipeline to capture HLS video segments:
```
ERROR: from element /GstPipeline:pipeline0/GstSplitMuxSink:splitmuxsink: Timestamping error on input streams
Additional debug info:
../gst/multifile/gstsplitmuxsink.c(2594): handle_gathered_gop (): /GstPipeline:pipeline0/GstSplitMuxSink:splitmuxsink:
Queued GOP time is negative -0:00:00.035816292
Execution ended after 0:22:00.008870101
```
The pipeline that produced this error is
```
$ gst-launch-1.0 rtspsrc location=rtsp://$USER:$PASSWORD@$IP is-live=true protocols=tcp \
! rtph264depay wait-for-keyframe=true request-keyframe=true \
! h264parse \
! splitmuxsink name=splitmuxsink max-size-time=10000000000 send-keyframe-requests=true muxer=mpegtsmux location=segment%05d.mp4
```
There should not be any errors when running the pipeline. I tried setting `config-interval=-1` on the `h264parse` node, but the issue persists.https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1016RTSP Could not open resource for reading2023-06-05T23:56:18ZSteven SparksRTSP Could not open resource for readingOn Gstreamer Core Library version 1.16.3
Linux 20.04 Nvidia Orin JetPack 5.0.2
Setup an RTSP server with:
<pre>
steven@development-orin:~$ ./test-launch "v4l2src device=/dev/video0 ! video/x-h264, width=640, height=480, framerate=30/1 !...On Gstreamer Core Library version 1.16.3
Linux 20.04 Nvidia Orin JetPack 5.0.2
Setup an RTSP server with:
<pre>
steven@development-orin:~$ ./test-launch "v4l2src device=/dev/video0 ! video/x-h264, width=640, height=480, framerate=30/1 ! h264parse ! rtph264pay name=pay0 pt=96"
stream ready at rtsp://127.0.0.1:8554/test
</pre>
as expected
Checked port to ensure processes is active:
<pre>
steven@development-orin:~$sudo ss -ltnp
State Recv-Q Send-Q Local Address:Port Peer Address:Port Process
LISTEN 0 5 127.0.0.1:8554 0.0.0.0:* users:(("test-launch",pid=8748,fd=4))
</pre>
as expected
Attempted display of video from my camera with:
<pre>
steven@development-orin:~$ gst-play-1.0 rtsp://127.0.0.1:8554/test
Press 'k' to see a list of keyboard shortcuts.
Now playing rtsp://127.0.0.1:8554/test
Pipeline is live.
<b>ERROR Could not open resource for reading. for rtsp://127.0.0.1:8554/test
ERROR debug information: gstrtspsrc.c(6232): gst_rtspsrc_setup_auth (): /GstPlayBin:playbin/GstURIDecodeBin:uridecodebin0/GstRTSPSrc:source:
No supported authentication protocol was found </b>
Reached end of play list.
</pre>
Not expected
Any ideas/suggestions that could help? The coding seems very standard. Possible bug?
Thanks!!https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1015mp4mux not writing tags to mp4 files2023-05-16T08:47:42ZXu Hump4mux not writing tags to mp4 filesHi, I have a pipeline constructed in C++, and its last step is to use splitmuxsink to write out mp4 files. I am using the default muxer i.e. mp4mux. Video writing has been working.
Now I need to add some video metadata, e.g. description...Hi, I have a pipeline constructed in C++, and its last step is to use splitmuxsink to write out mp4 files. I am using the default muxer i.e. mp4mux. Video writing has been working.
Now I need to add some video metadata, e.g. description and title.
```
auto* mp4mux = gst_element_factory_make("mp4mux", "mp4mux");
gst_tag_setter_add_tags(
GST_TAG_SETTER(mp4mux), GST_TAG_MERGE_KEEP, GST_TAG_DESCRIPTION,
"my desc", GST_TAG_COMMENT,
"my comment", GST_TAG_TITLE, "title", nullptr);
// Confirm the tags
// This prints \
// set tags: taglist, description=(string)"my\ desc", comment=(string)"my\ comment", title=(string)title;
GST_WARNING_OBJECT(GST_TAG_SETTER(mp4mux), "set tags: %" GST_PTR_FORMAT,
gst_tag_setter_get_tag_list(GST_TAG_SETTER(mp4mux)));
// Pass the muxer to splitmuxsink
// Start the pipeline
```
But the videos don't have any metadata I need when I check them with ffprobe:
```
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'video.mp4':
Metadata:
major_brand : mp42
minor_version : 0
compatible_brands: mp42mp41isomiso2
creation_time : 2023-05-16T08:08:18.000000Z
Duration: 467840:08:18.85, start: 1684224495.142000, bitrate: N/A
Stream #0:0(und): Subtitle: mov_text (tx3g / 0x67337874), 2592x291 (default)
Metadata:
creation_time : 2023-05-16T08:08:18.000000Z
handler_name : SubtitleHandler
Stream #0:1(und): Video: hevc (Main) (hvc1 / 0x31637668), yuv420p(tv), 2592x1944, SAR 1:1 DAR 4:3, 9.98 fps, 10 tbr, 1k tbn, 1k tbc (default)
Metadata:
creation_time : 2023-05-16T08:08:18.000000Z
handler_name : VideoHandler
```https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1014The process stops when linking 'rtspsrc' and 'rtph264depay'2023-05-08T11:09:33ZryupimThe process stops when linking 'rtspsrc' and 'rtph264depay'I would like to link 'rtspsrc' and 'h264depay'. But the process stops with the following message.
When I use ohter RTSP stream (ex. Wowza Stream test), it works fine. it doesn't output below message.
`
(gst-launch-1.0:678): GStreamer-W...I would like to link 'rtspsrc' and 'h264depay'. But the process stops with the following message.
When I use ohter RTSP stream (ex. Wowza Stream test), it works fine. it doesn't output below message.
`
(gst-launch-1.0:678): GStreamer-WARNING **: 10:12:15.620: External plugin loader failed. This most likely means that the plugin loader helper binary was not found or could not be run. You might need to set the GST_PLUGIN_SCANNER environment variable if your setup is unusual. This should normally not be required though.
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Progress: (open) Opening Stream
Pipeline is PREROLLED ...
Prerolled, waiting for progress to finish...
Progress: (connect) Connecting to rtsp://192.168.0.100:554/0/onvif/profile1/media.smp
Progress: (open) Retrieving server options
Progress: (open) Retrieving media info
Progress: (request) SETUP stream 0
Progress: (request) SETUP stream 1
Progress: (open) Opened Stream
Setting pipeline to PLAYING ...
New clock: GstSystemClock
Progress: (request) Sending PLAY request
Redistribute latency...
Redistribute latency...
Progress: (request) Sending PLAY request
Redistribute latency...
Redistribute latency...
Progress: (request) Sent PLAY request
Redistribute latency...
Redistribute latency...
Redistribute latency...
WARNING: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Delayed linking failed.
Additional debug info:
gst/parse/grammar.y(540): gst_parse_no_more_pads (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0:
failed delayed linking some pad of GstRTSPSrc named rtspsrc0 to some pad of GstRtpH264Depay named rtph264depay0
Redistribute latency...
`https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1013I want to stream RTSP stream data to AWS Kinesis Video Streaming using networ...2023-05-02T15:13:29ZryupimI want to stream RTSP stream data to AWS Kinesis Video Streaming using network camera "XNO-6120R"I want to stream RTSP stream data to AWS Kinesis Video Streaming using network camera "XNO-6120R".
A simple configuration is as follows.
Camera (XNO-6120R) --> Gstreamer (Ubuntu22.04 container) --> AWS KVS
After downloading the GStream...I want to stream RTSP stream data to AWS Kinesis Video Streaming using network camera "XNO-6120R".
A simple configuration is as follows.
Camera (XNO-6120R) --> Gstreamer (Ubuntu22.04 container) --> AWS KVS
After downloading the GStreamer package and building the AWS KVS SDK, I'm trying to transfer rtsp data with the following command, but an error is output.
- command1
`./kvs_gstraemer_sample $STREAM_NAME $RTSP_URL 2>&1 | tee /log/rtsp2kvs-kvsSample.log`
Output
<details><summary>Click to expand</summary>
[INFO ] [01-05-2023 07:28:37:713.777 GMT] Using region: ap-northeast-1
[INFO ] [01-05-2023 07:28:37:713.799 GMT] Using aws credentials for Kinesis Video Streams
[INFO ] [01-05-2023 07:28:37:713.802 GMT] No session token was detected.
[INFO ] [01-05-2023 07:28:37:714.361 GMT] createKinesisVideoClient(): Creating Kinesis Video Client
[INFO ] [01-05-2023 07:28:37:714.385 GMT] heapInitialize(): Initializing native heap with limit size 134217728, spill ratio 0% and flags 0x00000001
[INFO ] [01-05-2023 07:28:37:714.388 GMT] heapInitialize(): Creating AIV heap.
[INFO ] [01-05-2023 07:28:37:714.397 GMT] heapInitialize(): Heap is initialized OK
[DEBUG] [01-05-2023 07:28:37:714.449 GMT] getSecurityTokenHandler invoked
[DEBUG] [01-05-2023 07:28:37:714.463 GMT] Refreshing credentials. Force refreshing: 0 Now time is: 1682926117714454898 Expiration: 0
[INFO ] [01-05-2023 07:28:37:714.467 GMT] New credentials expiration is 1682929717
[INFO ] [01-05-2023 07:28:37:714.477 GMT] createDeviceResultEvent(): Create device result event.
[DEBUG] [01-05-2023 07:28:37:714.482 GMT] clientReadyHandler invoked
[DEBUG] [01-05-2023 07:28:37:714.497 GMT] Client is ready
[INFO ] [01-05-2023 07:28:37:714.526 GMT] Creating Kinesis Video Stream stream-test-20230424
[INFO ] [01-05-2023 07:28:37:714.538 GMT] createKinesisVideoStream(): Creating Kinesis Video Stream.
[INFO ] [01-05-2023 07:28:37:714.542 GMT] logStreamInfo(): SDK version: e99e7e94d897f309c773cb3bb677cab5c9b5f587
[DEBUG] [01-05-2023 07:28:37:714.545 GMT] logStreamInfo(): Kinesis Video Stream Info
[DEBUG] [01-05-2023 07:28:37:714.547 GMT] logStreamInfo(): Stream name: stream-test-20230424
[DEBUG] [01-05-2023 07:28:37:714.550 GMT] logStreamInfo(): Streaming type: STREAMING_TYPE_REALTIME
[DEBUG] [01-05-2023 07:28:37:714.552 GMT] logStreamInfo(): Content type: video/h264
[DEBUG] [01-05-2023 07:28:37:714.555 GMT] logStreamInfo(): Max latency (100ns): 600000000
[DEBUG] [01-05-2023 07:28:37:714.558 GMT] logStreamInfo(): Fragment duration (100ns): 20000000
[DEBUG] [01-05-2023 07:28:37:714.565 GMT] logStreamInfo(): Key frame fragmentation: Yes
[DEBUG] [01-05-2023 07:28:37:714.567 GMT] logStreamInfo(): Use frame timecode: Yes
[DEBUG] [01-05-2023 07:28:37:714.570 GMT] logStreamInfo(): Absolute frame timecode: Yes
[DEBUG] [01-05-2023 07:28:37:714.572 GMT] logStreamInfo(): Nal adaptation flags: 0
[DEBUG] [01-05-2023 07:28:37:714.575 GMT] logStreamInfo(): Average bandwith (bps): 4194304
[DEBUG] [01-05-2023 07:28:37:714.577 GMT] logStreamInfo(): Framerate: 25
[DEBUG] [01-05-2023 07:28:37:714.580 GMT] logStreamInfo(): Buffer duration (100ns): 1200000000
[DEBUG] [01-05-2023 07:28:37:714.582 GMT] logStreamInfo(): Replay duration (100ns): 400000000
[DEBUG] [01-05-2023 07:28:37:714.585 GMT] logStreamInfo(): Connection Staleness duration (100ns): 600000000
[DEBUG] [01-05-2023 07:28:37:714.587 GMT] logStreamInfo(): Store Pressure Policy: 1
[DEBUG] [01-05-2023 07:28:37:714.590 GMT] logStreamInfo(): View Overflow Policy: 1
[DEBUG] [01-05-2023 07:28:37:714.592 GMT] logStreamInfo(): Segment UUID: NULL
[DEBUG] [01-05-2023 07:28:37:714.595 GMT] logStreamInfo(): Frame ordering mode: 0
[DEBUG] [01-05-2023 07:28:37:714.597 GMT] logStreamInfo(): Track list
[DEBUG] [01-05-2023 07:28:37:714.600 GMT] logStreamInfo(): Track id: 1
[DEBUG] [01-05-2023 07:28:37:714.602 GMT] logStreamInfo(): Track name: kinesis_video
[DEBUG] [01-05-2023 07:28:37:714.605 GMT] logStreamInfo(): Codec id: V_MPEG4/ISO/AVC
[DEBUG] [01-05-2023 07:28:37:714.607 GMT] logStreamInfo(): Track type: TRACK_INFO_TYPE_VIDEO
[DEBUG] [01-05-2023 07:28:37:714.610 GMT] logStreamInfo(): Track cpd: NULL
[INFO ] [01-05-2023 07:28:37:929.061 GMT] writeHeaderCallback(): RequestId: ce6bbea4-ff93-464f-a324-6c04b757cc26
[DEBUG] [01-05-2023 07:28:37:929.103 GMT] describeStreamCurlHandler(): DescribeStream API response: {"StreamInfo":{"CreationTime":1.682322102808E9,"DataRetentionInHours":24,"DeviceName":null,"IngestionConfiguration":null,"KmsKeyId":"xxx","MediaType":null,"Status":"ACTIVE","Stre
(kvs_gstreamer_sample:1114): GStreamer-WARNING **: 07:28:38.165: External plugin loader failed. This most likely means that the plugin loader helper binary was not found or could not be run. You might need to set the GST_PLUGIN_SCANNER environment variable if your setup is unusual. This should normally not be required though.
amARN":"xxx","StreamName":"stream-test-20230424","Version":"TZsORArcf5fLv5mCq0IR"}}
[INFO ] [01-05-2023 07:28:37:929.770 GMT] describeStreamResultEvent(): Describe stream result event.
[WARN ] [01-05-2023 07:28:37:929.791 GMT] describeStreamResult(): Retention period returned from the DescribeStream call doesn't match the one specified in the StreamInfo
[WARN ] [01-05-2023 07:28:37:929.793 GMT] describeStreamResult(): Content type returned from the DescribeStream call doesn't match the one specified in the StreamInfo
[INFO ] [01-05-2023 07:28:38:157.736 GMT] writeHeaderCallback(): RequestId: 9a4a52f3-f75a-46f1-8795-bb1b5ff51522
[DEBUG] [01-05-2023 07:28:38:157.770 GMT] getStreamingEndpointCurlHandler(): GetStreamingEndpoint API response: {"DataEndpoint":"xxx"}
[INFO ] [01-05-2023 07:28:38:158.180 GMT] getStreamingEndpointResultEvent(): Get streaming endpoint result event.
[DEBUG] [01-05-2023 07:28:38:158.197 GMT] getStreamingTokenHandler invoked
[DEBUG] [01-05-2023 07:28:38:158.205 GMT] Refreshing credentials. Force refreshing: 1 Now time is: 1682926118158203675 Expiration: 1682929717
[INFO ] [01-05-2023 07:28:38:158.209 GMT] New credentials expiration is 1682929718
[INFO ] [01-05-2023 07:28:38:158.217 GMT] getStreamingTokenResultEvent(): Get streaming token result event.
[DEBUG] [01-05-2023 07:28:38:158.225 GMT] streamReadyHandler invoked
[DEBUG] [01-05-2023 07:28:38:158.362 GMT] Stream is ready
[INFO ] [01-05-2023 07:28:38:166.388 GMT] Streaming from rtsp source
New pad found: recv_rtp_src_0_3929480219_26
[INFO ] [01-05-2023 07:28:38:253.416 GMT] Pad link failed
New pad found: recv_rtp_src_1_45886901_107
</details>
GST_DEBUG=6 [rtsp2kvs-kvsSample_level6.log](/uploads/2b550d73fb27a724665c5a85be2d7349/rtsp2kvs-kvsSample_level6.log)
- command2
`gst-launch-1.0 rtspsrc location=$RTSP_URL protocols=udp short-header=TRUE ! \
rtph264depay ! \
h264parse ! \
kvssink stream-name=$STREAM_NAME 2>&1 | tee /log/rtsp2kvs-gstLaunch.log`
Output
<details><summary>Click to expand </summary>
(gst-launch-1.0:1065): GStreamer-WARNING **: 07:27:45.151: External plugin loader failed. This most likely means that the plugin loader helper binary was not found or could not be run. You might need to set the GST_PLUGIN_SCANNER environment variable if your setup is unusual. This should normally not be required though.
Setting pipeline to PAUSED ...
[INFO ] [01-05-2023 07:27:45:161.642 GMT] createKinesisVideoClient(): Creating Kinesis Video Client
[INFO ] [01-05-2023 07:27:45:161.692 GMT] heapInitialize(): Initializing native heap with limit size 134217728, spill ratio 0% and flags 0x00000001
[INFO ] [01-05-2023 07:27:45:161.697 GMT] heapInitialize(): Creating AIV heap.
[INFO ] [01-05-2023 07:27:45:161.712 GMT] heapInitialize(): Heap is initialized OK
[DEBUG] [01-05-2023 07:27:45:161.777 GMT] getSecurityTokenHandler invoked
[DEBUG] [01-05-2023 07:27:45:161.787 GMT] Refreshing credentials. Force refreshing: 0 Now time is: 1682926065161783781 Expiration: 0
[INFO ] [01-05-2023 07:27:45:161.796 GMT] createDeviceResultEvent(): Create device result event.
[DEBUG] [01-05-2023 07:27:45:161.803 GMT] clientReadyHandler invoked
[INFO ] [01-05-2023 07:27:45:161.826 GMT] try creating stream
[INFO ] [01-05-2023 07:27:45:161.841 GMT] Creating Kinesis Video Stream stream-test-20230424
[INFO ] [01-05-2023 07:27:45:161.847 GMT] createKinesisVideoStream(): Creating Kinesis Video Stream.
[INFO ] [01-05-2023 07:27:45:161.860 GMT] logStreamInfo(): SDK version: e99e7e94d897f309c773cb3bb677cab5c9b5f587
[DEBUG] [01-05-2023 07:27:45:161.864 GMT] logStreamInfo(): Kinesis Video Stream Info
[DEBUG] [01-05-2023 07:27:45:161.868 GMT] logStreamInfo(): Stream name: stream-test-20230424
[DEBUG] [01-05-2023 07:27:45:161.872 GMT] logStreamInfo(): Streaming type: STREAMING_TYPE_REALTIME
[DEBUG] [01-05-2023 07:27:45:161.876 GMT] logStreamInfo(): Content type: video/h264
[DEBUG] [01-05-2023 07:27:45:161.880 GMT] logStreamInfo(): Max latency (100ns): 600000000
[DEBUG] [01-05-2023 07:27:45:161.884 GMT] logStreamInfo(): Fragment duration (100ns): 20000000
[DEBUG] [01-05-2023 07:27:45:161.888 GMT] logStreamInfo(): Key frame fragmentation: Yes
[DEBUG] [01-05-2023 07:27:45:161.893 GMT] logStreamInfo(): Use frame timecode: Yes
[DEBUG] [01-05-2023 07:27:45:161.896 GMT] logStreamInfo(): Absolute frame timecode: Yes
[DEBUG] [01-05-2023 07:27:45:161.900 GMT] logStreamInfo(): Nal adaptation flags: 0
[DEBUG] [01-05-2023 07:27:45:161.904 GMT] logStreamInfo(): Average bandwith (bps): 4194304
[DEBUG] [01-05-2023 07:27:45:161.908 GMT] logStreamInfo(): Framerate: 25
[DEBUG] [01-05-2023 07:27:45:161.912 GMT] logStreamInfo(): Buffer duration (100ns): 1200000000
[DEBUG] [01-05-2023 07:27:45:161.916 GMT] logStreamInfo(): Replay duration (100ns): 400000000
[DEBUG] [01-05-2023 07:27:45:161.919 GMT] logStreamInfo(): Connection Staleness duration (100ns): 600000000
[DEBUG] [01-05-2023 07:27:45:161.924 GMT] logStreamInfo(): Store Pressure Policy: 1
[DEBUG] [01-05-2023 07:27:45:161.928 GMT] logStreamInfo(): View Overflow Policy: 1
[DEBUG] [01-05-2023 07:27:45:161.932 GMT] logStreamInfo(): Segment UUID: NULL
[DEBUG] [01-05-2023 07:27:45:161.936 GMT] logStreamInfo(): Frame ordering mode: 0
[DEBUG] [01-05-2023 07:27:45:161.940 GMT] logStreamInfo(): Track list
[DEBUG] [01-05-2023 07:27:45:161.944 GMT] logStreamInfo(): Track id: 1
[DEBUG] [01-05-2023 07:27:45:161.948 GMT] logStreamInfo(): Track name: kinesis_video
[DEBUG] [01-05-2023 07:27:45:161.952 GMT] logStreamInfo(): Codec id: V_MPEG4/ISO/AVC
[DEBUG] [01-05-2023 07:27:45:161.955 GMT] logStreamInfo(): Track type: TRACK_INFO_TYPE_VIDEO
[DEBUG] [01-05-2023 07:27:45:161.959 GMT] logStreamInfo(): Track cpd: NULL
[INFO ] [01-05-2023 07:27:45:372.623 GMT] writeHeaderCallback(): RequestId: 1a5b505b-9c0a-467b-91b8-bf151fe12615
[DEBUG] [01-05-2023 07:27:45:372.666 GMT] describeStreamCurlHandler(): DescribeStream API response: {"StreamInfo":{"CreationTime":1.682322102808E9,"DataRetentionInHours":24,"DeviceName":null,"IngestionConfiguration":null,"KmsKeyId":"arn:xxx","MediaType":null,"Status":"ACTIVE","StreamARN":"xxx","StreamName":"stream-test-20230424","Version":"TZsORArcf5fLv5mCq0IR"}}
[INFO ] [01-05-2023 07:27:45:373.222 GMT] describeStreamResultEvent(): Describe stream result event.
[WARN ] [01-05-2023 07:27:45:373.234 GMT] describeStreamResult(): Retention period returned from the DescribeStream call doesn't match the one specified in the StreamInfo
[WARN ] [01-05-2023 07:27:45:373.242 GMT] describeStreamResult(): Content type returned from the DescribeStream call doesn't match the one specified in the StreamInfo
[INFO ] [01-05-2023 07:27:45:563.142 GMT] writeHeaderCallback(): RequestId: 8c933c7d-832e-4308-bd7e-a691672d30ba
[DEBUG] [01-05-2023 07:27:45:563.179 GMT] getStreamingEndpointCurlHandler(): GetStreamingEndpoint API response: {"DataEndpoint":"xxx"}
[INFO ] [01-05-2023 07:27:45:563.701 GMT] getStreamingEndpointResultEvent(): Get streaming endpoint result event.
[DEBUG] [01-05-2023 07:27:45:563.719 GMT] getStreamingTokenHandler invoked
[DEBUG] [01-05-2023 07:27:45:563.727 GMT] Refreshing credentials. Force refreshing: 1 Now time is: 1682926065563724704 Expiration: 18446744073709551615
[INFO ] [01-05-2023 07:27:45:563.739 GMT] getStreamingTokenResultEvent(): Get streaming token result event.
[DEBUG] [01-05-2023 07:27:45:563.750 GMT] streamReadyHandler invoked
Stream is ready
Pipeline is live and does not need PREROLL ...
Progress: (open) Opening Stream
Pipeline is PREROLLED ...
Prerolled, waiting for progress to finish...
Progress: (connect) Connecting to rtsp://192.168.0.100:554/0/onvif/profile1/media.smp
Progress: (open) Retrieving server options
Progress: (open) Retrieving media info
Progress: (request) SETUP stream 0
Progress: (request) SETUP stream 1
Progress: (open) Opened Stream
Setting pipeline to PLAYING ...
New clock: GstSystemClock
Progress: (request) Sending PLAY request
Redistribute latency...
Redistribute latency...
Progress: (request) Sending PLAY request
Redistribute latency...
Redistribute latency...
Progress: (request) Sent PLAY request
Redistribute latency...
Redistribute latency...
Redistribute latency...
WARNING: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Delayed linking failed.
Additional debug info:
gst/parse/grammar.y(540): gst_parse_no_more_pads (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0:
failed delayed linking some pad of GstRTSPSrc named rtspsrc0 to some pad of GstRtpH264Depay named rtph264depay0
Redistribute latency...
</details>
GST_DEBUG=6 [rtsp2kvs-gstLaunch_level6.log](/uploads/93edab688ae83bd5b3cbddf2b60e6d2c/rtsp2kvs-gstLaunch_level6.log)
By the way, it correctly works on other systems that output RTSP stream data.
ex)
- rtsp://wowzaec2demo.streamlock.net/vod/mp4:BigBuckBunny_115k.mp4
- Live-Reporter ([link](https://apps.apple.com/us/app/live-reporter-live-camera/id996017825))
Please help me.https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1012mp4mux fails due to missing PTS2023-04-18T12:20:31ZFlorian Echtlermp4mux fails due to missing PTSI'm trying to record multiple H.264 and Opus streams to a MP4 file. However, there is apparently some sort of race condition going on, because in roughly 8 out of 10 attempts, the pipeline fails with the following error and an EOS:
gst-...I'm trying to record multiple H.264 and Opus streams to a MP4 file. However, there is apparently some sort of race condition going on, because in roughly 8 out of 10 attempts, the pipeline fails with the following error and an EOS:
gst-stream-error-quark: Could not multiplex stream. (10): ../gst/isomp4/gstqtmux.c(5402): gst_qt_mux_add_buffer (): /GstPipeline:pipeline0/GstBin:bin_file_sink/GstMP4Mux:mux: Buffer has no PTS.
In the other 20% of cases, the pipeline starts and the resulting MP4 file contains all the streams, correctly synchronized and playable. I also tried with qtmux instead of mp4mux, but got the same results.
I'm attaching the dot graph for the failure case [mp4mux-buffer-no-pts.dot](/uploads/e62dc9f5359dd0cabb54828e95888a43/mp4mux-buffer-no-pts.dot); the dot graph for a successful run looks exactly identical, with the only difference being that the filesink doesn't flag EOS.
This is currently running on GStreamer 1.20.3. I will try to also test with 1.22, and try to create a minimal reproducing example, but since this is a dynamically created pipeline, that may be difficult (note that the error never appears, e.g., when GST_DEBUG=4).https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1011gstrtpst2022-1-fecenc with appsink resulting not-linked errors2023-04-17T15:51:41Zyamen saraijigstrtpst2022-1-fecenc with appsink resulting not-linked errorsI am attempting to use FEC encoding to stream some data over the network, however whenever I use appsrc to feed the data to the pipeline, I get errors related to FEC not-linked, and no data would appear on the FEC sinks `rtp.send_fec_src...I am attempting to use FEC encoding to stream some data over the network, however whenever I use appsrc to feed the data to the pipeline, I get errors related to FEC not-linked, and no data would appear on the FEC sinks `rtp.send_fec_src_0_0` & `rtp.send_fec_src_0_1`. However, the x264 encoder is outputing data into sink `rtp.send_rtp_src_0`.
Is it an issue in the caps, or appsrc is incompatible with FEC encoding?
An example of the used pipeline:
```
rtpbin name=rtp do-retransmission=true do-lost=true fec-encoders="fec,0=\"rtpst2022-1-fecenc\ rows=5\ columns=5\";"
appsrc format=3 is-live=true name=vs0 ! capsfilter name=vs0_caps caps=video/x-raw,width=1280,height=720,format=I420,pixel-aspect-ratio=1/1,framerate=30/1,interlace-mode=progressive ! videoconvert ! queue ! x264enc name=vs0_enc sliced-threads=true bitrate=1000 key-int-max=10 pass=0 speed-preset=superfast tune=zerolatency ! video/x-h264,profile=constrained-baseline ! rtph264pay mtu=1200 config-interval=1 ssrc=0 ! application/x-rtp,payload=103 ! rtprtxqueue ! rtp.send_rtp_sink_0
rtp.send_rtp_src_0 ! udpsink name=rtp_vs0 host=127.0.0.1 port=3300
rtp.send_fec_src_0_0 ! udpsink name=rtcp_fec0_vs0 host=127.0.0.1 port=3303 async=false
rtp.send_fec_src_0_1 ! udpsink name=rtcp_fec1_vs0 host=127.0.0.1 port=3304 async=false
```
Resulting error log:
```rtpst2022-1-fecenc gstrtpst2022-1-fecenc.c:363:queue_fec_packet:<rtpst_2022_1_fecenc0:fec_1>�[00m Failed to push row FEC packet: not-linked
rtpst2022-1-fecenc gstrtpst2022-1-fecenc.c:363:queue_fec_packet:<rtpst_2022_1_fecenc0:fec_1>�[00m Failed to push row FEC packet: not-linked
rtpst2022-1-fecenc gstrtpst2022-1-fecenc.c:363:queue_fec_packet:<rtpst_2022_1_fecenc0:fec_1>�[00m Failed to push row FEC packet: not-linked
rtpst2022-1-fecenc gstrtpst2022-1-fecenc.c:363:queue_fec_packet:<rtpst_2022_1_fecenc0:fec_1>�[00m Failed to push row FEC packet: not-linked
rtpst2022-1-fecenc gstrtpst2022-1-fecenc.c:363:queue_fec_packet:<rtpst_2022_1_fecenc0:fec_1>�[00m Failed to push row FEC packet: not-linked
rtpst2022-1-fecenc gstrtpst2022-1-fecenc.c:398:gst_2d_fec_push_item_unlocked:<rtpst_2022_1_fecenc0:fec_0>�[00m Failed to push column FEC packet: not-linked
rtpst2022-1-fecenc gstrtpst2022-1-fecenc.c:363:queue_fec_packet:<rtpst_2022_1_fecenc0:fec_1>�[00m Failed to push row FEC packet: not-linked
rtpst2022-1-fecenc gstrtpst2022-1-fecenc.c:398:gst_2d_fec_push_item_unlocked:<rtpst_2022_1_fecenc0:fec_0>�[00m Failed to push column FEC packet: not-linked
rtpst2022-1-fecenc gstrtpst2022-1-fecenc.c:363:queue_fec_packet:<rtpst_2022_1_fecenc0:fec_1>�[00m Failed to push row FEC packet: not-linked
rtpst2022-1-fecenc gstrtpst2022-1-fecenc.c:398:gst_2d_fec_push_item_unlocked:<rtpst_2022_1_fecenc0:fec_0>�[00m Failed to push column FEC packet: not-linked
```https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1010qmlglsink: Feature request: implement QAbstractVideoFilter-like feature in Gs...2023-04-07T09:19:51ZVincas Dargisqmlglsink: Feature request: implement QAbstractVideoFilter-like feature in GstGLVideoItem for convenient way for getting QImages frome the samplesIn Qt Multimedia there's a way to install a filter https://doc.qt.io/qt-5/qabstractvideofilter.html into Qml `VideoOutput` which allows acquiring frames as `QImage`s and then perform some additional processing, like passing that image to...In Qt Multimedia there's a way to install a filter https://doc.qt.io/qt-5/qabstractvideofilter.html into Qml `VideoOutput` which allows acquiring frames as `QImage`s and then perform some additional processing, like passing that image to OpenCV algorithms.
Currently I presume one would have to modify pipeline to use `tee` and `appsink` and get frames via it, or to poll `last-sample` property using timer, after determining what is frame rate of the pipeline..?
Having optional mode there `GstGLVideoItem` would emit `QImage` on every sample or by introducing analogous "filter" runnable that would not block the pipeline, would make it much easier, without need to modify pipeline or do some other "gymnastics".https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1009rtpjpegdepay returning jpeg images that do not end in EOI (ff d9)2023-03-23T16:43:06ZJoey Trigortpjpegdepay returning jpeg images that do not end in EOI (ff d9)Hi!
I am running gstreamer on a number of rtsp streams each connected a different camera. For two specific cameras the output of gstreamer sometimes includes jpeg frames that are not valid jpegs - they do not end in an EOI marker (ff d9)...Hi!
I am running gstreamer on a number of rtsp streams each connected a different camera. For two specific cameras the output of gstreamer sometimes includes jpeg frames that are not valid jpegs - they do not end in an EOI marker (ff d9).
This is my command:
`gst-launch-1.0 -vv rtspsrc location=rtsp://USER:PASSWORD@IP:554/sub ! rtpjpegdepay ! multifilesink location="/tmp/frame%d.jpg"`
Here is an example of a 'bad' file from the first camera. Around 7% of the frames are invalid JPEGs:
```
$ file /tmp/frame24.jpg
/tmp/frame24.jpg: JPEG image data, baseline, precision 8, 640x360, components 3
$ hexdump -C /tmp/frame24.jpg | head -5
00000000 ff d8 ff db 00 43 00 10 0b 0c 0e 0c 0a 10 0e 0d |.....C..........|
00000010 0e 12 11 10 13 18 28 1a 18 16 16 18 31 23 25 1d |......(.....1#%.|
00000020 28 3a 33 3d 3c 39 33 38 37 40 48 5c 4e 40 44 57 |(:3=<9387@H\N@DW|
00000030 45 37 38 50 6d 51 57 5f 62 67 68 67 3e 4d 71 79 |E78PmQW_bghg>Mqy|
00000040 70 64 78 5c 65 67 63 ff db 00 43 01 11 12 12 18 |pdx\egc...C.....|
$ hexdump -C /tmp/frame24.jpg | tail -5
0000ab70 0f 9a 0e c7 a2 4f ab 4d 1c b7 16 96 16 c1 36 96 |.....O.M......6.|
0000ab80 55 2a 32 46 0e 09 0a 06 07 7a e4 6f 9a db cb 89 |U*2F.....z.o....|
0000ab90 60 20 b0 ce fc 2e 00 e7 8e 7b f1 59 34 51 6d 4d |` .......{.Y4QmM|
0000aba0 25 5a 3c 9c 91 8d bb bd d9 |%Z<......|
0000aba9
```
And some more:
```
$ hexdump -C /tmp/frame58.jpg | tail -5
0000ab70 a2 b0 6a ea cc e8 8d 59 41 de 0e c7 a2 4f ab 4b |..j....YA....O.K|
0000ab80 1c b7 16 96 16 c1 36 92 aa 54 67 18 24 12 14 70 |......6..Tg.$..p|
0000ab90 3b d7 23 7c d6 c5 22 10 10 58 67 7e 17 00 73 c7 |;.#|.."..Xg~..s.|
0000aba0 3d f8 ac 9a 28 b6 a6 92 ad 1e 4e 48 c6 dd d9 |=...(.....NH...|
0000abaf
$ hexdump -C /tmp/frame78.jpg | tail -5
0000ab70 8d 59 41 de 0e c7 a2 4f ab 4c 92 cf 69 61 6e 10 |.YA....O.L..ian.|
0000ab80 29 65 52 a3 38 c1 c1 21 47 03 bd 72 37 c6 db cb |)eR.8..!G..r7...|
0000ab90 89 60 20 b0 ce fc 2e 00 e7 8e 7b f1 59 34 51 6d |.` .......{.Y4Qm|
0000aba0 4d 25 5a 3c 9c 91 8d bb bd d9 |M%Z<......|
0000abaa
```
All of the files end in either `bd d9` or `dd d9`.
From the second camera things look a little different - I receive bad frames 15% of the time and the files all end in `15 9d 45 3b 12 d9`:
```
$ hexdump -C /tmp/frame85.jpg | tail -5
000056e0 e7 98 e6 59 15 47 a0 39 c5 61 51 45 82 e7 49 15 |...Y.G.9.aQE..I.|
000056f0 a4 50 8f ba 19 bd 5a a5 69 95 07 50 2b 96 a2 8e |.P....Z.i..P+...|
00005700 52 b9 8e 82 4d 46 24 fb a0 b9 aa 17 17 52 5c 36 |R...MF$......R\6|
00005710 4f 03 b0 15 9d 45 3b 12 d9 |O....E;..|
00005719
```
Now I assume that the camera is returning some kind of bad data (although I'm not sure why it's only happening for 2 cameras out of 100), but looking at the [code of rtpjpegdepay](https://github.com/GStreamer/gst-plugins-good/blob/master/gst/rtp/gstrtpjpegdepay.c#L708) I see that it is supposed to ensure that output jpeg's always end in EOI:
```
if (end[0] != 0xff && end[1] != 0xd9) {
GST_DEBUG_OBJECT (rtpjpegdepay, "no EOI marker, adding one");
/* no EOI marker, add one */
outbuf = gst_buffer_new_and_alloc (2);
gst_buffer_map (outbuf, &map, GST_MAP_WRITE);
map.data[0] = 0xff;
map.data[1] = 0xd9;
gst_buffer_unmap (outbuf, &map);
gst_adapter_push (rtpjpegdepay->adapter, outbuf);
avail += 2;
}
```
So I'm pretty sure that this is also a bug of some kind in rtpjpegdepay.https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1007gst-launch-1.0 crashes when using a G79 pipeline2023-03-01T14:36:57ZChristian Lalannegst-launch-1.0 crashes when using a G79 pipelineHello,
When testing this pipeline
```bash
gst-launch-1.0 -v udpsrc port=7002 caps="application/x-rtp" ! rtpg729depay ! avdec_g729 ! autoaudiosink
```
We send G729 to the port specified in the pipeline(7002),```gst-launch-1.0``` crashes ...Hello,
When testing this pipeline
```bash
gst-launch-1.0 -v udpsrc port=7002 caps="application/x-rtp" ! rtpg729depay ! avdec_g729 ! autoaudiosink
```
We send G729 to the port specified in the pipeline(7002),```gst-launch-1.0``` crashes with this error
```bash
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
/GstPipeline:pipeline0/GstUDPSrc:udpsrc0.GstPad:src: caps = application/x-rtp, media=(string)audio, clock-rate=(int)8000, encoding-name=(string)G729
New clock: GstSystemClock
/GstPipeline:pipeline0/GstRtpG729Depay:rtpg729depay0.GstPad:src: caps = audio/G729, channels=(int)1, rate=(int)8000
/GstPipeline:pipeline0/avdec_g729:avdec_g729-0.GstPad:sink: caps = audio/G729, channels=(int)1, rate=(int)8000
/GstPipeline:pipeline0/GstRtpG729Depay:rtpg729depay0.GstPad:sink: caps = application/x-rtp, media=(string)audio, clock-rate=(int)8000, encoding-name=(string)G729
WARNING: from element /GstPipeline:pipeline0/GstRtpG729Depay:rtpg729depay0: Could not decode stream.
Additional debug info:
../gst-libs/gst/rtp/gstrtpbasedepayload.c(829): gst_rtp_base_depayload_handle_buffer (): /GstPipeline:pipeline0/GstRtpG729Depay:rtpg729depay0:
Received invalid RTP payload, dropping
WARNING: from element /GstPipeline:pipeline0/GstRtpG729Depay:rtpg729depay0: Could not decode stream.
Additional debug info:
../gst-libs/gst/rtp/gstrtpbasedepayload.c(829): gst_rtp_base_depayload_handle_buffer (): /GstPipeline:pipeline0/GstRtpG729Depay:rtpg729depay0:
Received invalid RTP payload, dropping
/GstPipeline:pipeline0/avdec_g729:avdec_g729-0.GstPad:src: caps = audio/x-raw, format=(string)S16LE, layout=(string)non-interleaved, rate=(int)8000, channels=(int)1
ERROR: from element /GstPipeline:pipeline0/GstUDPSrc:udpsrc0: Internal data stream error.
Additional debug info:
../libs/gst/base/gstbasesrc.c(3127): gst_base_src_loop (): /GstPipeline:pipeline0/GstUDPSrc:udpsrc0:
streaming stopped, reason not-negotiated (-4)
Execution ended after 0:00:08.981875302
Setting pipeline to NULL ...
ERROR: from element /GstPipeline:pipeline0/avdec_g729:avdec_g729-0: Could not decode stream.
Additional debug info:
../gst-libs/gst/audio/gstaudiodecoder.c(1589): gst_audio_decoder_finish_frame_or_subframe (): /GstPipeline:pipeline0/avdec_g729:avdec_g729-0:
Received decoded subframe, but no pending frame
Freeing pipeline ...
```
**version gst-launch:** 1.20.3
Why this is crashing? any help will be welcome, thanks.https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1006splitmuxsink CAPS promiscuity is not helpful2023-05-30T09:47:56Zbarneysplitmuxsink CAPS promiscuity is not helpful1.18.4
gstsplitmuxsink declares `ANY` for each of its `request` pads. This makes it extremely difficult to ask for, say, a subtitle stream - all pads will say 'yeah, we can do that!' Upstream needs to know about downstream, breaking man...1.18.4
gstsplitmuxsink declares `ANY` for each of its `request` pads. This makes it extremely difficult to ask for, say, a subtitle stream - all pads will say 'yeah, we can do that!' Upstream needs to know about downstream, breaking many principles.
I'm currently working around that by sticking `splitmuxsink` in a bin and remedying the CAPS declared by pad.
But that's exposed a shortcoming in `gst_element_link_filtered` which doesnt actively ensure it's likely to workhttps://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1005rtspsrc: Stream timeout after 30sec, potential QoS - jitter related?2023-02-17T09:20:04Zrobbyfrtrtspsrc: Stream timeout after 30sec, potential QoS - jitter related?Hi Gstreamer Community,
I am trying to use an Rtsp Stream from a Meraki Camera in a containerised Gstreamer application on an Nvidia Jetson Device. See the links at the bottom for the same question addressed towards nvidia (already clos...Hi Gstreamer Community,
I am trying to use an Rtsp Stream from a Meraki Camera in a containerised Gstreamer application on an Nvidia Jetson Device. See the links at the bottom for the same question addressed towards nvidia (already closed) and meraki (no response yet).
The following pipeline stops after a while:
```gst-launch-1.0 --gst-debug rtspsrc:5 rtspsrc location=rtsp://172.17.15.148:9000/live latency=200 protocols=tcp ! rtph264depay ! h264parse ! avdec_h264 ! fakesink```
The log shows the following inf for `rtspsrc`:
```
0:00:39.012627424 2031 0xaaaac8c00cc0 DEBUG rtspsrc gstrtspsrc.c:5292:gst_rtspsrc_handle_data:<rtspsrc0> pushing data of size 1456 on channel 0
0:00:39.012745889 2031 0xaaaac8c00cc0 DEBUG rtspsrc gstrtspsrc.c:5483:gst_rtspsrc_loop_interleaved:<rtspsrc0> doing receive with timeout 21 seconds, 149197 usec
0:00:41.013121788 2031 0xffff8003fc00 DEBUG rtspsrc gstrtspsrc.c:3116:gst_rtspsrc_sink_chain:<rtspsrc0> sending 84 bytes RTCP
0:00:41.013578336 2031 0xffff8003fc00 DEBUG rtspsrc gstrtspsrc.c:3118:gst_rtspsrc_sink_chain:<rtspsrc0> sent RTCP, 0
0:00:44.398050795 2031 0xffff8003fc00 DEBUG rtspsrc gstrtspsrc.c:3116:gst_rtspsrc_sink_chain:<rtspsrc0> sending 84 bytes RTCP
0:00:44.399698872 2031 0xffff8003fc00 DEBUG rtspsrc gstrtspsrc.c:3118:gst_rtspsrc_sink_chain:<rtspsrc0> sent RTCP, 0
0:00:49.452082450 2031 0xffff8003fc00 DEBUG rtspsrc gstrtspsrc.c:3116:gst_rtspsrc_sink_chain:<rtspsrc0> sending 60 bytes RTCP
0:00:49.453826399 2031 0xffff8003fc00 DEBUG rtspsrc gstrtspsrc.c:3118:gst_rtspsrc_sink_chain:<rtspsrc0> sent RTCP, 0
0:00:55.313793770 2031 0xffff8003fc00 DEBUG rtspsrc gstrtspsrc.c:3116:gst_rtspsrc_sink_chain:<rtspsrc0> sending 60 bytes RTCP
0:00:55.316535838 2031 0xffff8003fc00 DEBUG rtspsrc gstrtspsrc.c:3118:gst_rtspsrc_sink_chain:<rtspsrc0> sent RTCP, 0
0:00:59.033220662 2031 0xaaaac8c00cc0 DEBUG rtspsrc gstrtspsrc.c:5501:gst_rtspsrc_loop_interleaved:<rtspsrc0> timeout, sending keep-alive
0:00:59.033310679 2031 0xaaaac8c00cc0 DEBUG rtspsrc gstrtspsrc.c:5190:gst_rtspsrc_send_keep_alive:<rtspsrc0> creating server keep-alive
0:00:59.033840859 2031 0xaaaac8c00cc0 DEBUG rtspsrc gstrtspsrc.c:5483:gst_rtspsrc_loop_interleaved:<rtspsrc0> doing receive with timeout 59 seconds, 999994 usec
0:01:00.382545984 2031 0xffff8003fc00 DEBUG rtspsrc gstrtspsrc.c:3116:gst_rtspsrc_sink_chain:<rtspsrc0> sending 60 bytes RTCP
0:01:00.382947171 2031 0xffff8003fc00 DEBUG rtspsrc gstrtspsrc.c:3118:gst_rtspsrc_sink_chain:<rtspsrc0> sent RTCP, 0
0:01:06.059474662 2031 0xffff8003fc00 WARN rtspsrc gstrtspsrc.c:3458:on_timeout_common:<rtspsrc0> source 7d70c1fa, stream 7d70c1fa in session 0 timed out
0:01:06.059559815 2031 0xffff8003fc00 DEBUG rtspsrc gstrtspsrc.c:3418:gst_rtspsrc_do_stream_eos:<rtspsrc0> setting stream for session 0 to EOS
Got EOS from element "pipeline0".
Execution ended after 0:01:05.899511216
Setting pipeline to NULL ...
```
Setting `latency=50000` increases the lifetime of the pipeline from 30sec to ~10min so it seems like I have a performance problem.
I am using TCP, as UDP does not want to connect.
Running the stream via `ffplay` actually stops as well after a few minutes. This however can be resolved when setting `-reorder_queue_size 0`, which as far as I know disables jitter buffering ([StackOverflow](https://stackoverflow.com/questions/51762823/can-someone-explain-the-reorder-queue-size-option-of-rtsp-input-in-ffmpeg)).
Are there any parameters I should try to solve this problem? Any hints on what I could test?
https://forums.developer.nvidia.com/t/rtsp-source-stops-working-after-30s-qos-issue/242961
https://community.meraki.com/t5/Smart-Cameras/Stable-connection-via-External-RTSP-gt-30min/m-p/185034#M3214https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1004rtspsrc: wrong location constructed for SETUP request when content_base is pr...2023-05-30T09:48:25ZMatthias Mewisrtspsrc: wrong location constructed for SETUP request when content_base is providedI have an IP camera that provides `content_base` information in reply to DESCRIBE request with a path portion but without the trailing "/".
HTTP-Header of camera's reply:
```RTSP/1.0 200 OK
CSeq: 3
Server: Rtsp Server 2304*1296*15*4096...I have an IP camera that provides `content_base` information in reply to DESCRIBE request with a path portion but without the trailing "/".
HTTP-Header of camera's reply:
```RTSP/1.0 200 OK
CSeq: 3
Server: Rtsp Server 2304*1296*15*4096
Content-Type: application/sdp
Content-length: 390
Content-Base: rtsp://192.168.31.168/0
```
When gstrtspsrc.c creates SETUP request, `content_base` and relative `control_path` information are joined:
> base = "rtsp://192.168.31.168/0"
>
> control_path = "trackID=0"
>
> `stream->conninfo.location = gst_uri_join_strings (base, control_path)` -> rtsp://192.168.31.168/trackID=0 (wrong)
Whereas a base path with a trailing "/" results in a correct location:
> base = "rtsp://192.168.31.168/0/"
>
> control_path = "trackID=0"
>
> `stream->conninfo.location = gst_uri_join_strings (base, control_path)` -> rtsp://192.168.31.168/0/trackID=0
Appending a "/" to `content_base` when receiving it in `gst_rtspsrc_create_stream()` seems sufficient to me. But I don't know if this is a general solution or has other effects.https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1003Application after migrating from gstreamer 1.14 to 1.18 fails to load and run...2023-07-01T19:03:09ZalexovaiApplication after migrating from gstreamer 1.14 to 1.18 fails to load and run the pipeline.I have a simple application that connects to rtsp source and gets rgb frame and outputs in sink. The pipeline is described below
`gst-launch-1.0 uridecodebin uri=rtsp://<username>:<password>@<ip_address>/live use-buffering=true name=vx_...I have a simple application that connects to rtsp source and gets rgb frame and outputs in sink. The pipeline is described below
`gst-launch-1.0 uridecodebin uri=rtsp://<username>:<password>@<ip_address>/live use-buffering=true name=vx_source ! queue2 name=queue3 ! videoconvert ! videoscale ! video/x-raw,format=RGB ! appsink name=appsink sync=false emit-signals=true max-buffers=1 drop=true`
The application is run via python3-gst binding inside a docker (debian-buster-slim) with gstreamer 1.14.
The application runs fine and has been running it for about a year now continuously.
Recently I was trying to upgrade the gstreamer from 1.14 -> 1.18. I wanted gstreamer-vaapi to use iHD driver on newer intel machines.
I changed the docker os from debian-buster-slim -> debian-bullseye-slim and reinstalled all the libraries including gstreamer and ffmpeg.
Now my docker had gstreamer-1.18. Here is the installation script I have in the Dockerfile.
`sudo apt-get install -y libgstreamer1.0-0 gstreamer1.0-plugins-base \
gstreamer1.0-plugins-good gstreamer1.0-plugins-bad gstreamer1.0-plugins-ugly \
gstreamer1.0-libav \
gstreamer1.0-tools gstreamer1.0-x gstreamer1.0-alsa gstreamer1.0-gl gstreamer1.0-gtk3 \
gstreamer1.0-pulseaudio \
python3-gst-1.0 python3-gi`
After this upgrade, my application stopped running and then I started digging into the gstreamer using GST_DEBUG="*:4"
I captured logs from both debian-buster-slim gstreamer 1.14 & debian-bullseye-slim gstreamer 1.18 and after comparing I found that
application when on 1.14 is able to successfully load the libgstudp.so however application in 1.18 doesn't. This ultimately causes the pipeline not to load and run as expected.
I am new to gstreamer and if there is any advice to further debug this issue or have any other pointers please let me know. Thanks
Logs with GST_DEBUG="*:4"
[gst_log_1.14](/uploads/15d46466d4fe1dd2a281dc54ef074f9f/gst_log_1.14)
[gst_log_1.18](/uploads/4cb872e3b3524a3cb067e0b3c096614b/gst_log_1.18)https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1002rtspsrc request-key callback for srtpdec is not setting attributes2023-01-10T10:04:43ZXavier Rovirartspsrc request-key callback for srtpdec is not setting attributesTarget: rtspsrc from an ip camera via RTSP/SRTP where the suite, key and salt is provided via request-key callback is not working.
It seems internal srtp_dec is not set with the provided data.
Looking the code:
In this part suite and k...Target: rtspsrc from an ip camera via RTSP/SRTP where the suite, key and salt is provided via request-key callback is not working.
It seems internal srtp_dec is not set with the provided data.
Looking the code:
In this part suite and key is provided via callback to the upper app. if no callback caps by default is provided.
static GstRTSPResult gst_rtspsrc_setup_streams_start (GstRTSPSrc * src, gboolean async)
{
.
/* set up keys */
if (stream->profile == GST_RTSP_PROFILE_SAVP ||
stream->profile == GST_RTSP_PROFILE_SAVPF) {
hval = gst_rtspsrc_stream_make_keymgmt (src, stream);
gst_rtsp_message_take_header (&request, GST_RTSP_HDR_KEYMGMT, hval);
}
}
static gchar *
gst_rtspsrc_stream_make_keymgmt (GstRTSPSrc * src, GstRTSPStream * stream)
{
gchar *base64, *result = NULL;
GstMIKEYMessage *mikey_msg;
stream->srtcpparams = signal_get_srtcp_params (src, stream);
if (stream->srtcpparams == NULL)
stream->srtcpparams = default_srtcp_params ();
}
This part above is ok.
But request_rtp_decoder do not set attributes for decrypt.
static GstElement *
request_rtp_decoder (GstElement * rtpbin, guint session, GstRTSPStream * stream)
{
GST_DEBUG ("decoder session %u, stream %p, %d", session, stream, stream->id);
if (stream->id != session)
return NULL;
if (stream->profile != GST_RTSP_PROFILE_SAVP &&
stream->profile != GST_RTSP_PROFILE_SAVPF)
return NULL;
if (stream->srtpdec == NULL) {
gchar *name;
name = g_strdup_printf ("srtpdec_%u", session);
stream->srtpdec = gst_element_factory_make ("srtpdec", name);
g_free (name);
if (stream->srtpdec == NULL) {
GST_ELEMENT_ERROR (stream->parent, CORE, MISSING_PLUGIN, (NULL),
("no srtpdec element present!"));
return NULL;
}
g_signal_connect (stream->srtpdec, "request-key",
(GCallback) request_key, stream);
}
return gst_object_ref (stream->srtpdec);
}
static GstCaps *
request_key (GstElement * srtpdec, guint ssrc, GstRTSPStream * stream)
{
guint i;
GstCaps *caps;
GstMIKEYMessage *msg = stream->mikey;
GST_DEBUG ("request key SSRC %u", ssrc);
caps = gst_caps_ref (stream_get_caps_for_pt (stream, stream->default_pt));
caps = gst_caps_make_writable (caps);
/* parse crypto sessions and look for the SSRC rollover counter */
msg = stream->mikey;
for (i = 0; msg && i < gst_mikey_message_get_n_cs (msg); i++) {
const GstMIKEYMapSRTP *map = gst_mikey_message_get_cs_srtp (msg, i);
if (ssrc == map->ssrc) {
gst_caps_set_simple (caps, "roc", G_TYPE_UINT, map->roc, NULL);
break;
}
}
return caps;
}
But if you look request_rtp_encoder you can see the funcion uses stream->srtcpparams to set srtp_enc.
So, why request_rtp_decoder can not use suite and key provided by stream->srtcpparams via request-key to application?
Or rtspsrc only can work via mikey attribute in DESCRIBE?. I would like to provide the suite and key via request-key because they are obtained via https call.
Best regards,https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/1001qmloverlay: running example in eglfs platform fails2023-05-30T09:59:21ZDariusz Venovskiqmloverlay: running example in eglfs platform failsCompiling and running qmloverlay example in the gst-plugins-good/test/examples/qt dir.
App runs fine under X, but when run over eglfs platform fails with error:
```EGLFS: OpenGL windows cannot be mixed with others.```
- GStreamer 1.21....Compiling and running qmloverlay example in the gst-plugins-good/test/examples/qt dir.
App runs fine under X, but when run over eglfs platform fails with error:
```EGLFS: OpenGL windows cannot be mixed with others.```
- GStreamer 1.21.3 (GIT)
- Qt 5.15.2
- Linux