looping back a stream from Mediasoup-->gstreamer-->mediasoup without re-encoding

i am consuming h264 video from mediasoup in gstreamer and then again sending back the same stream to mediasoup on a plain trasport.
if mediasoup sends an h264 encoded stream to gstreamer then I should be able to send the stream back to mediasoup without re-encoding it with gstreamer.
i am able to receive the stream back in mediaosup if i re-encode the stream to h264 in gstreamer before sending it to mediasoup.
but i what to get rid of re-encoding.

(working) re-ending pipeline
udpsrc -- rtph264depay -- decodebin -- x264enc -- rtph264pay --udpsink

i tried to send the stream back without re-encoding but it does not works
(not working ) without re-encoding
udpsrc -- rtph264depay -- h264parse -- rtph264pay --udpsink

1 Like

Bytes are received on the plain transport but no video is displayed on client
transport stats with 2 sec interval

[
  {
    bytesReceived: 504,
    bytesSent: 0,
    comedia: true,
    multiSource: false,
    probationBytesSent: 0,
    probationSendBitrate: 0,
    recvBitrate: 0,
    rtcpMux: false,
    rtcpTuple: {
      localIp: '127.0.0.1',
      localPort: 22726,
      protocol: 'udp',
      remoteIp: '127.0.0.1',
      remotePort: 45144
    },
    rtpBytesReceived: 0,
    rtpBytesSent: 0,
    rtpRecvBitrate: 0,
    rtpSendBitrate: 0,
    rtxBytesReceived: 0,
    rtxBytesSent: 0,
    rtxRecvBitrate: 0,
    rtxSendBitrate: 0,
    sendBitrate: 0,
    timestamp: 2512634,
    transportId: '458d867d-5f54-4bce-a6e1-31e930e4b64a',
    tuple: { localIp: '127.0.0.1', localPort: 33736, protocol: 'udp' },
    type: 'plain-rtp-transport'
  }
]
[
  {
    bytesReceived: 588,
    bytesSent: 0,
    comedia: true,
    multiSource: false,
    probationBytesSent: 0,
    probationSendBitrate: 0,
    recvBitrate: 0,
    rtcpMux: false,
    rtcpTuple: {
      localIp: '127.0.0.1',
      localPort: 22726,
      protocol: 'udp',
      remoteIp: '127.0.0.1',
      remotePort: 45144
    },
    rtpBytesReceived: 0,
    rtpBytesSent: 0,
    rtpRecvBitrate: 0,
    rtpSendBitrate: 0,
    rtxBytesReceived: 0,
    rtxBytesSent: 0,
    rtxRecvBitrate: 0,
    rtxSendBitrate: 0,
    sendBitrate: 0,
    timestamp: 2514635,
    transportId: '458d867d-5f54-4bce-a6e1-31e930e4b64a',
    tuple: { localIp: '127.0.0.1', localPort: 33736, protocol: 'udp' },
    type: 'plain-rtp-transport'
  }
]
[
  {
    bytesReceived: 588,
    bytesSent: 0,
    comedia: true,
    multiSource: false,
    probationBytesSent: 0,
    probationSendBitrate: 0,
    recvBitrate: 0,
    rtcpMux: false,
    rtcpTuple: {
      localIp: '127.0.0.1',
      localPort: 22726,
      protocol: 'udp',
      remoteIp: '127.0.0.1',
      remotePort: 45144
    },
    rtpBytesReceived: 0,
    rtpBytesSent: 0,
    rtpRecvBitrate: 0,
    rtpSendBitrate: 0,
    rtxBytesReceived: 0,
    rtxBytesSent: 0,
    rtxRecvBitrate: 0,
    rtxSendBitrate: 0,
    sendBitrate: 0,
    timestamp: 2516637,
    transportId: '458d867d-5f54-4bce-a6e1-31e930e4b64a',
    tuple: { localIp: '127.0.0.1', localPort: 33736, protocol: 'udp' },
    type: 'plain-rtp-transport'
  }
]
[
  {
    bytesReceived: 588,
    bytesSent: 0,
    comedia: true,
    multiSource: false,
    probationBytesSent: 0,
    probationSendBitrate: 0,
    recvBitrate: 0,
    rtcpMux: false,
    rtcpTuple: {
      localIp: '127.0.0.1',
      localPort: 22726,
      protocol: 'udp',
      remoteIp: '127.0.0.1',
      remotePort: 45144
    },
    rtpBytesReceived: 0,
    rtpBytesSent: 0,
    rtpRecvBitrate: 0,
    rtpSendBitrate: 0,
    rtxBytesReceived: 0,
    rtxBytesSent: 0,
    rtxRecvBitrate: 0,
    rtxSendBitrate: 0,
    sendBitrate: 0,
    timestamp: 2518638,
    transportId: '458d867d-5f54-4bce-a6e1-31e930e4b64a',
    tuple: { localIp: '127.0.0.1', localPort: 33736, protocol: 'udp' },
    type: 'plain-rtp-transport'
  }
]```