[vlc-commits] d3d9_fmt: no need for a video_format to create an external D3D9 device

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


vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Wed Jun 26 08:48:00 2019 +0200| [76453fa57a35fd9c9eddd8e8dae5e0c7c3612fe1] | committer: Steve Lhomme

d3d9_fmt: no need for a video_format to create an external D3D9 device

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

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

diff --git a/modules/codec/avcodec/dxva2.c b/modules/codec/avcodec/dxva2.c
index 4899a6be3a..d9c6f5efd6 100644
--- a/modules/codec/avcodec/dxva2.c
+++ b/modules/codec/avcodec/dxva2.c
@@ -278,7 +278,7 @@ static int Open(vlc_va_t *va, AVCodecContext *ctx, enum PixelFormat pix_fmt,
             goto error;
         }
         if ( D3D9_CreateExternal(va, &sys->hd3d, device) != VLC_SUCCESS ||
-             FAILED(D3D9_CreateDeviceExternal( device, &sys->hd3d, 0, &fmt->video, &sys->d3d_dev)) )
+             FAILED(D3D9_CreateDeviceExternal( device, &sys->hd3d, 0, &sys->d3d_dev)) )
         {
             IDirect3DDevice9_Release(device);
             free( sys );
diff --git a/modules/video_chroma/d3d9_fmt.c b/modules/video_chroma/d3d9_fmt.c
index 5a7d842a72..2d280d8c49 100644
--- a/modules/video_chroma/d3d9_fmt.c
+++ b/modules/video_chroma/d3d9_fmt.c
@@ -135,7 +135,7 @@ HRESULT D3D9_CreateDevice(vlc_object_t *o, d3d9_handle_t *hd3d, HWND hwnd,
 }
 
 HRESULT D3D9_CreateDeviceExternal(IDirect3DDevice9 *dev, d3d9_handle_t *hd3d, HWND hwnd,
-                                  const video_format_t *source, d3d9_device_t *out)
+                                  d3d9_device_t *out)
 {
     D3DDEVICE_CREATION_PARAMETERS params;
     HRESULT hr = IDirect3DDevice9_GetCreationParameters(dev, &params);
diff --git a/modules/video_chroma/d3d9_fmt.h b/modules/video_chroma/d3d9_fmt.h
index 099ac8bc43..bd688f4bdd 100644
--- a/modules/video_chroma/d3d9_fmt.h
+++ b/modules/video_chroma/d3d9_fmt.h
@@ -99,7 +99,7 @@ HRESULT D3D9_CreateDevice(vlc_object_t *, d3d9_handle_t *, HWND,
                           const video_format_t *, d3d9_device_t *out);
 #define D3D9_CreateDevice(a,b,c,d,e) D3D9_CreateDevice( VLC_OBJECT(a), b, c, d, e )
 HRESULT D3D9_CreateDeviceExternal(IDirect3DDevice9 *, d3d9_handle_t *, HWND,
-                                  const video_format_t *, d3d9_device_t *out);
+                                  d3d9_device_t *out);
 
 void D3D9_ReleaseDevice(d3d9_device_t *);
 int D3D9_Create(vlc_object_t *, d3d9_handle_t *);
diff --git a/modules/video_output/win32/direct3d9.c b/modules/video_output/win32/direct3d9.c
index 98d4899a12..8f7ecb5ee3 100644
--- a/modules/video_output/win32/direct3d9.c
+++ b/modules/video_output/win32/direct3d9.c
@@ -1509,7 +1509,7 @@ static int Direct3D9Open(vout_display_t *vd, video_format_t *fmt,
 
     if (external_dev)
         hr = D3D9_CreateDeviceExternal(external_dev, &sys->hd3d, sys->sys.hvideownd,
-                                       &vd->source, &sys->d3d_dev);
+                                       &sys->d3d_dev);
     else
         hr = D3D9_CreateDevice(vd, &sys->hd3d, sys->sys.hvideownd,
                                &vd->source, &sys->d3d_dev);



More information about the vlc-commits mailing list