<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On 4 Jan 2023, at 7:29 am, Nicolas Dufresne via gstreamer-devel <<a href="mailto:gstreamer-devel@lists.freedesktop.org" class="">gstreamer-devel@lists.freedesktop.org</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><meta charset="UTF-8" class=""><div dir="auto" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 24px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><div class="">Any chance you could share a trace with env GST_DEBUG="*v4l*:7,2" ?<br class=""><br class=""><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Le mar. 3 janv. 2023, 10 h 46, James via gstreamer-devel <<a href="mailto:gstreamer-devel@lists.freedesktop.org" class="">gstreamer-devel@lists.freedesktop.org</a>> a écrit :<br class=""></div><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-style: solid; border-left-color: rgb(204, 204, 204); padding-left: 1ex;">I'm avoiding any reference to the rude rant a few days back.<br class=""><br class="">I tried/tested lots before writing code which has worked somewhere (ubuntu 22.04 with gst 18 that stutters audio, SUSE tumbleweed gst 20..latest.)<br class=""><br class="">All parcelled up and " Failed to allocate required memory" reared it's ugly head.<br class=""><br class="">Either branch runs perfectly on it's own, starting the other fails.<br class="">I run one channel from my code. Take one of my tests<br class=""><br class="">dvr@dvrTW:~> cat gst.try55<br class="">gst-launch-1.0 -v v4l2src device=/dev/video2 ! image/jpeg,framerate=30/1 \<br class="">       <span class="Apple-converted-space"> </span>! jpegdec ! \<br class="">       videoconvert ! \<br class="">queue max-size-buffers=0 max-size-bytes=0 max-size-time=1000000000 ! \<br class="">gdkpixbufoverlay location=rennisons.png alpha=0.5 offset-x=1800 offset-y=900 ! \<br class="">clockoverlay halignment=left valignment=top draw-outline=true font-desc="Sans, 12" time-format="%d %b %Y %H:%M:%S" ! \<br class="">textoverlay text="This is Line 1"               deltay=50  halignment=left valignment=top font-desc="Sans, 10"                    draw-outline=true ! \<br class="">textoverlay text="Line 2"               deltay=100 halignment=left valignment=top font-desc="Sans, 10"                    draw-outline=true ! \<br class="">textoverlay text="Look it works" deltax=50 deltay=150 halignment=left valignment=top font-desc="Cantarell Oblique Medium 20" draw-outline=true ! \<br class="">textoverlay                             deltay=200 halignment=left valignment=top font-desc="Sans, 10"                    draw-outline=true ! \<br class="">textoverlay text="Line 5"               deltay=250 halignment=left valignment=top font-desc="Sans, 10"                    draw-outline=true ! \<br class="">textoverlay                             deltay=300 halignment=left valignment=top font-desc="Sans, 10"                    draw-outline=true ! \<br class="">textoverlay                             deltay=350 halignment=left valignment=top font-desc="Sans, 10"                    draw-outline=true ! \<br class="">textoverlay                             deltay=400 halignment=left valignment=top font-desc="Sans, 10"                    draw-outline=true ! \<br class="">textoverlay text="Why"                  deltay=450 halignment=left valignment=top font-desc="Sans, 10"                    draw-outline=true ! \<br class="">textoverlay text="Line 10"              deltay=500 halignment=left valignment=top font-desc="AdobeTimes Bold 10"          draw-outline=true ! \<br class="">       tee name=t \<br class="">       <span class="Apple-converted-space"> </span>t. ! queue ! xvimagesink sync=false \<br class="">       t. ! queue ! \<br class="">       <span class="Apple-converted-space"> </span>x264enc speed-preset=ultrafast tune=zerolatency byte-stream=true bitrate=4000 ! \<br class="">       <span class="Apple-converted-space"> </span>mpegtsmux name=mux ! \<br class="">       <span class="Apple-converted-space"> </span>filesink location='try55.mp4'<br class=""><br class=""><br class="">and run it<br class=""><br class="">dvr@dvrTW:~> ./gst.try55<br class="">Setting pipeline to PAUSED ...<br class="">Pipeline is live and does not need PREROLL ...<br class="">Pipeline is PREROLLED ...<br class="">Setting pipeline to PLAYING ...<br class="">New clock: GstSystemClock<br class="">/GstPipeline:pipeline0/GstV4l2Src:v4l2src0.GstPad:src: caps = image/jpeg, framerate=(fraction)30/1, width=(int)1920, height=(int)1080, pixel-aspect-ratio=(fraction)1/1, interlace-mode=(string)progressive, colorimetry=(string)2:4:5:1<br class="">/GstPipeline:pipeline0/GstCapsFilter:capsfilter0.GstPad:src: caps = image/jpeg, framerate=(fraction)30/1, width=(int)1920, height=(int)1080, pixel-aspect-ratio=(fraction)1/1, interlace-mode=(string)progressive, colorimetry=(string)2:4:5:1<br class="">/GstPipeline:pipeline0/GstJpegDec:jpegdec0.GstPad:sink: caps = image/jpeg, framerate=(fraction)30/1, width=(int)1920, height=(int)1080, pixel-aspect-ratio=(fraction)1/1, interlace-mode=(string)progressive, colorimetry=(string)2:4:5:1<br class="">/GstPipeline:pipeline0/GstCapsFilter:capsfilter0.GstPad:sink: caps = image/jpeg, framerate=(fraction)30/1, width=(int)1920, height=(int)1080, pixel-aspect-ratio=(fraction)1/1, interlace-mode=(string)progressive, colorimetry=(string)2:4:5:1<br class="">ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Failed to allocate required memory.<br class="">Additional debug info:<br class="">../sys/v4l2/gstv4l2src.c(777): gst_v4l2src_decide_allocation (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:<br class="">Buffer pool activation failed<br class="">Execution ended after 0:00:00.005402443<br class="">ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Internal data stream error.<br class="">Setting pipeline to NULL ...<br class="">Additional debug info:<br class="">../libs/gst/base/gstbasesrc.c(3127): gst_base_src_loop (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:<br class="">streaming stopped, reason not-negotiated (-4)<br class="">Freeing pipeline ...<br class=""><br class="">Can anybody point me in a direction that solves it please.<br class=""><br class="">I emphasize that somewhere during testing I had 4 channels all running, every channel runs it's own copy of gstreamer and AFAICT each copy is totally independant. We *must* be looking at some resource<br class="">This is running on i7x4 and htop shows 50% cpu and memory used.<br class=""><br class="">The messing around with jpeg was a suggestion from Nicolas. Each capture card is USB3 in a USB3 port, but the system treated them as USB2 and limited resolution (1280x800 IIRC instead of 1080P)<br class=""></blockquote></div></div><div dir="auto" class=""><br class=""></div><div dir="auto" class="">If it was still a lack of bandwidth, UVC driver should be messaging you through dmesg. </div></div></div></blockquote><br class=""></div><div>I'll revert and look but the crux is solved!</div><div><br class=""></div><div>The jpeg fiddle was your suggestion to get 1080 on a usb-3 port. The error message was caused by having 2 capture cards on (a hub) a single usb-3 port even though that is quite legal (in terms of bandwidth).</div><div>I will also try 2 cards on a usb-c.</div><div>Then to find the culprit gstreamer or UVC driver.</div><div><br class=""></div><div>My m2 adapter is S-L-O-W but on a standard flash disk I can hold 500Mb/s on the usb-3 port.</div><div>Someone pretends the usb-3 is a usb-2: who?</div><div><br class=""></div><div>James</div><div><br class=""></div><div><div class=""><br class=""></div></div></body></html>