<div dir="auto"><div><br><div class="gmail_extra"><br><div class="gmail_quote">Le 12 mars 2017 4:35 AM, "Sean DuBois" <<a href="mailto:sean@siobud.com">sean@siobud.com</a>> a écrit :<br type="attribution"><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hey list!<br>
<br>
I am attempting to combine a mixture of live and non-live sources, however I am having trouble<br>
with the audiomixer dropping audio. The following is my example pipeline, however the audio is lost from my rtmpsrc.<br>
The rtmpsrc is 'live' it is a h264/aac FLV and is is produced from a remote camera on the fly.</blockquote></div></div></div><div dir="auto"><div class="gmail_extra"><div class="gmail_quote"><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
```<br>
#include <gst/gst.h><br>
<br>
int main(int argc, char *argv[]) {<br>
  gst_init(&argc, &argv);<br>
<br>
  auto *loop = g_main_loop_new(NULL, FALSE);<br>
  auto *pipeline = gst_parse_launch(<br>
      "videotestsrc is-live=true ! compositor name=c ! video/x-raw,width=1280,height=<wbr>720 ! queue ! autovideosink "<br>
      "audiotestsrc volume=0.0 is-live=true ! audiomixer name=a ! queue ! autoaudiosink "<br>
      "rtmpsrc location=\"rtmp://localhost/<wbr>serve/live\" ! decodebin name=d ! videoconvert name=vconv ! queue ! c. d. ! audioconvert name=aconv ! queue ! a.",<br>
      NULL);<br>
<br>
  gst_element_set_state(<wbr>pipeline, GST_STATE_PLAYING);<br>
  g_main_loop_run(loop);<br>
<br>
  return 0;<br>
}<br>
````<br>
<br>
If I remove `is-live=true` from the videotestsrc and audiotestsrc the audio works.<br>
If I add latency=2000000000 to the compositor/audiomixer the audio works.<br>
<br>
However, I can't add the latency attribute because other srcs on the audiomixer/compositor (rtp) break things very quickly<br></blockquote></div></div></div><div dir="auto"><br></div><div dir="auto">Can you clarify how it fails for you? You need some latency for this to work, but 2s might bee to much. You would need enough latency on rtp jitter buffer too.</div><div dir="auto"><div class="gmail_extra"><div class="gmail_quote"><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
One thing I do find peculiar is that the compositor always works it is just empty, there is some difference in logic/state<br>
between the audiomixer/compositor (where the compositor behavior is the well behaving one)<br></blockquote></div></div></div><div dir="auto"><br></div><div dir="auto">Video is simpler to deal with, since you can repeat frames without you noticing.</div><div dir="auto"><br></div><div dir="auto"><div class="gmail_extra"><div class="gmail_quote"><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
I also can do a GST_PAD_PROBE_BUFFER and add ~2 seconds to the PTS of the raw audio buffers on the audioconvert sink pad, and that fixes it as well.<br>
However I don't understand where that 2 second of loss is coming from? I would like to measure/understand, before I do a hack<br>
like that.<br>
<br>
So if anyone has any ideas/can point out what I am doing wrong I would love to hear!<br>
<br>
thanks<br>
______________________________<wbr>_________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.<wbr>freedesktop.org</a><br>
<a href="https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" rel="noreferrer" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/gstreamer-<wbr>devel</a><br>
</blockquote></div><br></div></div></div>