[vlc-commits] directx_va: remove the unused lock

Steve Lhomme git at videolan.org
Tue Jun 13 15:01:16 CEST 2017


vlc | branch: master | Steve Lhomme <robux4 at videolabs.io> | Mon May 29 15:16:46 2017 +0200| [d1a36cdde1252999480c765566a6dd6f539db8e9] | committer: Jean-Baptiste Kempf

directx_va: remove the unused lock

Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=d1a36cdde1252999480c765566a6dd6f539db8e9
---

 modules/codec/avcodec/directx_va.c | 5 -----
 modules/codec/avcodec/directx_va.h | 2 --
 2 files changed, 7 deletions(-)

diff --git a/modules/codec/avcodec/directx_va.c b/modules/codec/avcodec/directx_va.c
index a90e3155cf..577f3c6eff 100644
--- a/modules/codec/avcodec/directx_va.c
+++ b/modules/codec/avcodec/directx_va.c
@@ -356,7 +356,6 @@ int directx_va_Setup(vlc_va_t *va, directx_sys_t *dx_sys, AVCodecContext *avctx)
             return VLC_ENOMEM;
         }
         atomic_init(&surface->refcount, 1);
-        surface->p_lock = &dx_sys->surface_lock;
         surface->p_pic = dx_sys->pf_alloc_surface_pic(va, &fmt, i);
         dx_sys->surface[i] = surface;
     }
@@ -448,8 +447,6 @@ void directx_va_Close(vlc_va_t *va, directx_sys_t *dx_sys)
 
     if (dx_sys->hdecoder_dll)
         FreeLibrary(dx_sys->hdecoder_dll);
-
-    vlc_mutex_destroy( &dx_sys->surface_lock );
 }
 
 int directx_va_Open(vlc_va_t *va, directx_sys_t *dx_sys,
@@ -457,8 +454,6 @@ int directx_va_Open(vlc_va_t *va, directx_sys_t *dx_sys,
 {
     dx_sys->codec_id = ctx->codec_id;
 
-    vlc_mutex_init( &dx_sys->surface_lock );
-
     if (b_dll) {
         /* Load dll*/
         dx_sys->hdecoder_dll = LoadLibrary(dx_sys->psz_decoder_dll);
diff --git a/modules/codec/avcodec/directx_va.h b/modules/codec/avcodec/directx_va.h
index 299127e977..44840922a6 100644
--- a/modules/codec/avcodec/directx_va.h
+++ b/modules/codec/avcodec/directx_va.h
@@ -45,7 +45,6 @@
 /* */
 typedef struct {
     atomic_uintptr_t     refcount;
-    vlc_mutex_t        *p_lock;
     picture_t          *p_pic;
     D3D_DecoderSurface *decoderSurface;
 } vlc_va_surface_t;
@@ -82,7 +81,6 @@ typedef struct
     int          surface_width;
     int          surface_height;
 
-    vlc_mutex_t      surface_lock;
     vlc_va_surface_t     *surface[MAX_SURFACE_COUNT];
     D3D_DecoderSurface  *hw_surface[MAX_SURFACE_COUNT];
 



More information about the vlc-commits mailing list