[vlc-commits] d3d9_fmt: share the is_d3d9_opaque() code

Steve Lhomme git at videolan.org
Wed Jun 26 12:06:21 CEST 2019


vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Wed Jun 26 08:28:04 2019 +0200| [7981ae9b98b95bdabb5d0b626d3ab6d37af34d28] | committer: Steve Lhomme

d3d9_fmt: share the is_d3d9_opaque() code

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

 modules/video_chroma/d3d9_fmt.h        | 12 ++++++++++++
 modules/video_output/win32/direct3d9.c | 12 ------------
 2 files changed, 12 insertions(+), 12 deletions(-)

diff --git a/modules/video_chroma/d3d9_fmt.h b/modules/video_chroma/d3d9_fmt.h
index db371a3108..099ac8bc43 100644
--- a/modules/video_chroma/d3d9_fmt.h
+++ b/modules/video_chroma/d3d9_fmt.h
@@ -67,6 +67,18 @@ typedef struct
     D3DCAPS9                caps;
 } d3d9_device_t;
 
+static inline bool is_d3d9_opaque(vlc_fourcc_t chroma)
+{
+    switch (chroma)
+    {
+    case VLC_CODEC_D3D9_OPAQUE:
+    case VLC_CODEC_D3D9_OPAQUE_10B:
+        return true;
+    default:
+        return false;
+    }
+}
+
 static inline void AcquireD3D9PictureSys(picture_sys_d3d9_t *p_sys)
 {
     IDirect3DSurface9_AddRef(p_sys->surface);
diff --git a/modules/video_output/win32/direct3d9.c b/modules/video_output/win32/direct3d9.c
index 5637ab3fb9..98d4899a12 100644
--- a/modules/video_output/win32/direct3d9.c
+++ b/modules/video_output/win32/direct3d9.c
@@ -199,18 +199,6 @@ typedef struct d3d_region_t {
 } d3d_region_t;
 
 /* */
-static bool is_d3d9_opaque(vlc_fourcc_t chroma)
-{
-    switch (chroma)
-    {
-    case VLC_CODEC_D3D9_OPAQUE:
-    case VLC_CODEC_D3D9_OPAQUE_10B:
-        return true;
-    default:
-        return false;
-    }
-}
-
 static HINSTANCE Direct3D9LoadShaderLibrary(void)
 {
     HINSTANCE instance = NULL;



More information about the vlc-commits mailing list