Webrtc over h265 in Safari not working
Hello: I am trying to do a communication from gstreamer to Safari browser using h265 codec in sendonly mode. I have previously tested this codec over webrtc so I am sure that the browser supports it since webkit implements it (checked with https://github.com/webrtc/samples/tree/gh-pages/src/content/peerconnection/change-codecs).
I have started from the example in https://gitlab.freedesktop.org/gstreamer/gstreamer/-/blob/main/subprojects/gst-examples/webrtc/sendonly/webrtc-unidirectional-h264.c modifying the pipeline. My final pipeline is as follows:
webrtcbin name=webrtcbin videotestsrc ! videorate ! videoscale ! video/x-raw,width=640,height=360,framerate=15/1 ! videoconvert ! queue max-size-buffers=1 ! x265enc speed-preset=ultrafast ! video/x-h265,profile=main ! queue max-size-time=100000000 ! h265parse ! rtph265pay config-interval=-1 ! application/x-rtp,media=video,encoding-name=H265,payload=104 ! webrtcbin.
When opening the browser I get a response to the offer it makes but the video does not start. The exchange of sdp messages is as follows:
Negotiation offer created:
v=0
o=- 3139870788961411982 0 IN IP4 0.0.0.0
s=-
t=0 0
a=ice-options:trickle
m=video 9 UDP/TLS/RTP/SAVPF 104
c=IN IP4 0.0.0.0
a=setup:actpass
a=ice-ufrag:U+LQ8nCvY6BLMk5WyDEtLvrV8316GDKG
a=ice-pwd:bi/+EvkAzGYw3hjnPbf1IFJoeM9nr+MJ
a=rtcp-mux
a=rtcp-rsize
a=sendonly
a=rtpmap:104 H265/90000
a=rtcp-fb:104 nack pli
a=rtcp-fb:104 transport-cc
a=framerate:15
a=fmtp:104 sprop-vps=QAEMAf//AWAAAAMAkAAAAwAAAwA/lZQJ;sprop-sps=QgEBAWAAAAMAkAAAAwAAAwA/oAUCAXHy5ZWVKTC//AAEAAWoMDAwIAAAAwAgAAADAeE=;sprop-pps=RAHAc8GJ
a=ssrc:675092278 msid:user2875715355@host-224904eb webrtctransceiver0
a=ssrc:675092278 cname:user2875715355@host-224904eb
a=mid:video0
a=fingerprint:sha-256 9D:76:AA:8F:0B:0E:13:62:39:1E:EB:F0:37:1D:EA:EC:08:AF:55:C3:91:A5:D8:A8:B2:A0:33:56:0A:F5:F9:BF
a=rtcp-mux-only
Received SDP:
v=0
o=- 819066822958699861 2 IN IP4 127.0.0.1
s=-
t=0 0
a=msid-semantic: WMS
m=video 9 UDP/TLS/RTP/SAVPF 104
c=IN IP4 0.0.0.0
a=rtcp:9 IN IP4 0.0.0.0
a=ice-ufrag:EGPk
a=ice-pwd:O4oCuUmeXLA/3BxXEO86inXZ
a=ice-options:trickle
a=fingerprint:sha-256 7F:EE:88:1C:61:D5:9C:73:D2:39:C4:D5:80:4E:5F:A6:99:20:12:38:39:5C:01:5E:A5:6B:E9:BF:E4:5B:36:E9
a=setup:active
a=mid:video0
a=recvonly
a=rtcp-mux
a=rtcp-rsize
a=rtpmap:104 H265/90000
a=rtcp-fb:104 transport-cc
a=rtcp-fb:104 nack pli
My last log in the example is:
Received ICE candidate with mline index 0; candidate: candidate:1283376487 1 udp 2122260223 b755ed98-c42c-4e75-a1e6-fb1a9600383c.local 61936 typ host generation 0 ufrag EGPk network-id 1 network-cost 50
but nothing happens. Thanks in advance