# Can't decode frames on client encoded using NVENC

**URL:** https://mediasoup.discourse.group/t/cant-decode-frames-on-client-encoded-using-nvenc/1908
**Category:** Integration
**Created:** [October 21, 2020, 11:16pm UTC](https://mediasoup.discourse.group/t/cant-decode-frames-on-client-encoded-using-nvenc/1908 "2020-10-21T23:16:32Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![MoizAhmedd](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/moizahmedd/32/803_2.png) [@MoizAhmedd](https://mediasoup.discourse.group/u/MoizAhmedd)
#### Post date: [October 21, 2020, 11:16pm UTC](https://mediasoup.discourse.group/t/cant-decode-frames-on-client-encoded-using-nvenc/1908/1 "2020-10-21T23:16:32Z")

</div>

I have been using x264enc for a while with no issues encoding/decoding frames. However I have recently switched to nvenc and am experiencing issues get a stream.

When I send a stream using gstreamer with the following pipeline:

`C:\gstreamer\1.0\mingw_x86_64\bin\gst-launch-1.0.exe rtpbin name=rtpbin rtp-profile=avpf dxgiscreencapsrc ! queue ! videorate ! video/x-raw,framerate=20/1 ! videoconvert ! video/x-raw,format=I420,framerate=20/1 ! nvh264enc zerolatency=true preset=1 ! "video/x-h264,profile=(string)high" ! h264parse ! rtph264pay ssrc=22222222 ! "application/x-rtp,payload=(int)123" ! rtpbin.send_rtp_sink_0 rtpbin.send_rtp_src_0 ! udpsink bind-address=172.31.3.209 host=172.31.3.209 bind-port=5004 port=39629 rtpbin.send_rtcp_src_0 ! udpsink bind-address=172.31.3.209 host=172.31.3.209 port=26936 sync=false async=false udpsrc port=5005 ! rtpbin.recv_rtcp_sink_0`

As well as the following media soup options and video producers:

```
videoProducer = await video_producer_transport.produce({
    kind: "video",
    rtpParameters: {
        codecs: [
            {
                mimeType: "video/H264",
                clockRate: 90000,
                payloadType: 123,
                parameters: {
                    "packetization-mode": 1,
                    "profile-level-id": "640032",
                    "level-asymmetry-allowed": 1,
                },
            },
        ],
        encodings: [{ ssrc: 22222222, scalabilityMode: "S1T1" }],
    },
});

mediasoup_options = { worker: {
    rtcMinPort: 10000,
    rtcMaxPort: 10100,
    logLevel: "warn",
    logTags: ["info", "ice", "dtls", "rtp", "srtp", "rtcp"],
},
router: {
    mediaCodecs: [
        {
            kind: "audio",
            mimeType: "audio/opus",
            clockRate: 48000,
            channels: 2,
        },
        {
            kind: "video",
            mimeType: "video/H264",
            clockRate: 90000,
            parameters: {
                "packetization-mode": 1,
                "profile-level-id": "640032",
                "level-asymmetry-allowed": 1,
            },
        },
    ],
},
webRtcTransport: {
    listenIps: [
        { ip: get_local_ip_address(), announcedIp: external_ip_address },
    ],
    enableUdp: true,
    preferUdp: true,
    maxIncomingBitrate: 1500000,
    initialAvailableOutgoingBitrate: 1000000,
},

```

I am able to receive packets, and frames however almost all the frames are being dropped without a single frame being decoded

It shows a few key frames decoded however even that is very low

Here is my webrtc get stats

 ![image](https://global.discourse-cdn.com/free1/uploads/mediasoup/original/1X/11cb40fad30914e49e6f256cea9a0a5980cd3b06.png)

Is there any issue with my pipeline or is it to do with my mediasoup options?

---

<div class="post-metadata">

### Author: ![josefhernandez](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/josefhernandez/32/1609_2.png) [@josefhernandez](https://mediasoup.discourse.group/u/josefhernandez)
#### Post date: [September 8, 2024, 10:00am UTC](https://mediasoup.discourse.group/t/cant-decode-frames-on-client-encoded-using-nvenc/1908/2 "2024-09-08T10:00:34Z")

</div>

did you solve it?  
I’m having exactly the same problem  
I need to send 10 h264 real-time videos, nvh264enc is my only option
