Sfoglia il codice sorgente

Unref frames before decoding with FFMPEG (#2704)

gdkchan 4 anni fa
parent
commit
f7aaea4300
1 ha cambiato i file con 2 aggiunte e 0 eliminazioni
  1. 2 0
      Ryujinx.Graphics.Nvdec.H264/FFmpegContext.cs

+ 2 - 0
Ryujinx.Graphics.Nvdec.H264/FFmpegContext.cs

@@ -106,6 +106,8 @@ namespace Ryujinx.Graphics.Nvdec.H264
 
 
         public int DecodeFrame(Surface output, ReadOnlySpan<byte> bitstream)
         public int DecodeFrame(Surface output, ReadOnlySpan<byte> bitstream)
         {
         {
+            ffmpeg.av_frame_unref(output.Frame);
+
             int result;
             int result;
             int gotFrame;
             int gotFrame;