<div dir="ltr">Wow that was it. h264parse's config interval! Thank you so much. Fortunately I still had that branch and that one property change got me going. <div><br></div><div>You are a lifesaver. And I'm a total h264 newb. Again, thanks. </div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Dec 9, 2020 at 3:46 PM Sean DuBois <<a href="mailto:sean@siobud.com">sean@siobud.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hey,<br>
<br>
Lots of things can go wrong here, but these are the big ones I have run<br>
into!<br>
<br>
* Make sure you have a SPS/PPS with every IDR. GStreamer doesn't do that<br>
  by default. `config-interval=-1` on `h264parse` will fix that.<br>
<br>
* Make sure your PayloadTypes/SSRCes are correct. I don't believe this<br>
  is the issue since Chrome sees the incoming media. But I see this bite<br>
  a lot of people when the implementation doesn't handle this for them.<br>
<br>
* Make sure your browser supports the H264 profile. I don't believe this<br>
  is an issue since you are doing Chrome <-> Chrome. One thing to note<br>
  that Chrome doesn't support H264 on all platforms (Chromium on Debian<br>
  has no H264, and Android builds with hardware support)<br>
<br>
* General packet loss/ordering woes? Repacketizing could be exacerbating<br>
  issues. You could be transforming an out of order/lossy stream to an<br>
  in order one.<br>
<br>
* Lots of other possible issues :) I would try saving the RTP stream to<br>
  disk and using a tool to analyze it further. Just so you can know all<br>
  the attributes you are working with.<br>
<br>
On Wed, Dec 09, 2020 at 01:52:29PM -0600, Trey Hutcheson wrote:<br>
> I can't get Chrome to understand or render h264 content sent by another<br>
> chrome peer. Honestly I have no idea where the problem is. Here's the<br>
> scenario:<br>
> * chrome (87) produces an offer with h264 video, sendonly, and connects to<br>
> one instance of webrtcbin<br>
> * A second remote peer connects to a second instance of webrtcbin. In this<br>
> case, webrtcbin produces the offer. I connect video content received from<br>
> webrtcbin1 to webrtcbin2, by repayloading (webrtcbin1 > rtph264depay ><br>
> rtph264pay > webrtcbin2). Webrtcbin produces an offer with h264 video. The<br>
> second chrome peer  responds with an answer, accepting the offer.<br>
> * The second chrome peer fires the ontrack event for the new video stream,<br>
> but it doesn't actually understand the video. I've attached the stream to a<br>
> video element, but it doesn't render. Furthermore,<br>
> chrome://webrtc-internals reports "unknown" for the codec and the<br>
> decoderImplementation.<br>
><br>
> Now, to narrow things down, on the server side I have tried taking the<br>
> stream received from webrtcbin1 and rendering it onscreen (rtp624depay<br>
> ! avdec_h264 ! videoconvert ! videoscale ! autovideosink) and it renders<br>
> just fine, proving that at the least the rtp is decoded properly and the<br>
> h264 decode process produces good video. Thus - the chrome provided video<br>
> must be correct.<br>
><br>
> I've also tried inserting an h264parse element between the depay and<br>
> payload elements, and that had no effect.<br>
><br>
> I have *also* tried depayloading, decoding, re-encoding, and re-payloading,<br>
> and that works just fine. Remote side understands the stream.<br>
><br>
> For the record, I'm using the following code to make chrome provide h264:<br>
><br>
> const video_transceiver = peer.addTransceiver('video', {"direction":<br>
> "sendonly"})<br>
> const capabilities = RTCRtpSender.getCapabilities('video')<br>
> const noVP8 = capabilities.codecs<br>
>     .filter(codec => codec.mimeType.toLocaleLowerCase() != "video/vp8")<br>
>     .filter(codec => codec.mimeType.toLocaleLowerCase() != "video/vp9");<br>
> video_transceiver.setCodecPreferences(noVP8);<br>
><br>
> Does anyone have any insight?<br>
<br>
> _______________________________________________<br>
> gstreamer-devel mailing list<br>
> <a href="mailto:gstreamer-devel@lists.freedesktop.org" target="_blank">gstreamer-devel@lists.freedesktop.org</a><br>
> <a href="https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" rel="noreferrer" target="_blank">https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
<br>
_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org" target="_blank">gstreamer-devel@lists.freedesktop.org</a><br>
<a href="https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" rel="noreferrer" target="_blank">https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
</blockquote></div>