Hello everyone!

I have encountered a problem on using VMR9AlphaBitmap structure in
"vmr9.h". According to
https://docs.microsoft.com/en-us/windows/win32/directshow/directshow-structures
, the `rDest` field of the structure is 'immediate', though the current
mingw-w64 definition is a pointer. Actually, I can use the structure
with no problem only if I modify it to the immediate one.

At first, I tried generating "vmr9.h" from "vmr9.idl" by WIDL 5.0-rc1, but
some declarations in the generated header changed from WINBOOL to BOOL..
WINBOOL seems desirable according to mailing list logs, so I have edited
it without WIDL.
From 61d0b5eba3f253650acb7fdec724cb906f9e3c1d Mon Sep 17 00:00:00 2001
From: xtne6f <xt4...@gmail.com>
Date: Wed, 4 Mar 2020 18:19:01 +0900
Subject: [PATCH] include: Fix definition of VMR9AlphaBitmap

Signed-off-by: xtne6f <xt4...@gmail.com>
---
 mingw-w64-headers/include/vmr9.h   | 2 +-
 mingw-w64-headers/include/vmr9.idl | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/mingw-w64-headers/include/vmr9.h b/mingw-w64-headers/include/vmr9.h
index 6de45159..89a26597 100644
--- a/mingw-w64-headers/include/vmr9.h
+++ b/mingw-w64-headers/include/vmr9.h
@@ -1314,7 +1314,7 @@ typedef struct _VMR9AlphaBitmap {
     HDC hdc;
     IDirect3DSurface9 *pDDS;
     RECT rSrc;
-    VMR9NormalizedRect *rDest;
+    VMR9NormalizedRect rDest;
     FLOAT fAlpha;
     COLORREF clrSrcKey;
     DWORD dwFilterMode;
diff --git a/mingw-w64-headers/include/vmr9.idl 
b/mingw-w64-headers/include/vmr9.idl
index bb3681cd..410f6162 100644
--- a/mingw-w64-headers/include/vmr9.idl
+++ b/mingw-w64-headers/include/vmr9.idl
@@ -272,7 +272,7 @@ typedef struct _VMR9AlphaBitmap
     HDC hdc;
     IDirect3DSurface9 *pDDS;
     RECT rSrc;
-    VMR9NormalizedRect *rDest;
+    VMR9NormalizedRect rDest;
     FLOAT fAlpha;
     COLORREF clrSrcKey;
     DWORD dwFilterMode;
-- 
2.25.1

_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to