Rebase against 18e2df401eb545f0ce490daaaf12a6c1c248119f.

This commit is contained in:
Zebediah Figura
2018-09-10 20:28:36 -05:00
parent 28e66e552f
commit 6e0d8f18d9
11 changed files with 29 additions and 939 deletions

View File

@@ -1,27 +1,18 @@
From 2c97bba1bdd02bb72d185635c7f162024be521b4 Mon Sep 17 00:00:00 2001
From 794bad144407eaaa1c046984dae2942d75a7afe1 Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Thu, 23 Aug 2018 12:22:07 +1000
Subject: [PATCH 1/3] mfplat: Forward IMFMediaType to IMFAttributes
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
dlls/mfplat/main.c | 166 ++++++++++++---------------------------------
1 file changed, 42 insertions(+), 124 deletions(-)
dlls/mfplat/main.c | 164 ++++++++++++++---------------------------------------
1 file changed, 41 insertions(+), 123 deletions(-)
diff --git a/dlls/mfplat/main.c b/dlls/mfplat/main.c
index df61f3cdc9..744f074b56 100644
index 9f381ef..ee9be91 100644
--- a/dlls/mfplat/main.c
+++ b/dlls/mfplat/main.c
@@ -31,7 +31,7 @@
#include "mfapi.h"
#include "mfidl.h"
#include "mferror.h"
-
+#include "wine/heap.h"
#include "wine/debug.h"
#include "wine/unicode.h"
@@ -890,6 +890,12 @@ static const IMFAttributesVtbl mfattributes_vtbl =
@@ -1148,6 +1148,12 @@ static const IMFAttributesVtbl mfattributes_vtbl =
mfattributes_CopyAllItems
};
@@ -34,7 +25,7 @@ index df61f3cdc9..744f074b56 100644
/***********************************************************************
* MFCreateAttributes (mfplat.@)
*/
@@ -903,10 +909,9 @@ HRESULT WINAPI MFCreateAttributes(IMFAttributes **attributes, UINT32 size)
@@ -1161,10 +1167,9 @@ HRESULT WINAPI MFCreateAttributes(IMFAttributes **attributes, UINT32 size)
if(!object)
return E_OUTOFMEMORY;
@@ -47,7 +38,7 @@ index df61f3cdc9..744f074b56 100644
return S_OK;
}
@@ -1077,6 +1082,7 @@ HRESULT WINAPI MFCreateSourceResolver(IMFSourceResolver **resolver)
@@ -1335,6 +1340,7 @@ HRESULT WINAPI MFCreateSourceResolver(IMFSourceResolver **resolver)
typedef struct _mfmediatype
{
@@ -55,7 +46,7 @@ index df61f3cdc9..744f074b56 100644
IMFMediaType IMFMediaType_iface;
LONG ref;
} mfmediatype;
@@ -1137,269 +1143,179 @@ static ULONG WINAPI mediatype_Release(IMFMediaType *iface)
@@ -1395,269 +1401,179 @@ static ULONG WINAPI mediatype_Release(IMFMediaType *iface)
static HRESULT WINAPI mediatype_GetItem(IMFMediaType *iface, REFGUID key, PROPVARIANT *value)
{
mfmediatype *This = impl_from_IMFMediaType(iface);
@@ -354,7 +345,7 @@ index df61f3cdc9..744f074b56 100644
}
static HRESULT WINAPI mediatype_CopyAllItems(IMFMediaType *iface, IMFAttributes *dest)
@@ -1510,14 +1426,16 @@ HRESULT WINAPI MFCreateMediaType(IMFMediaType **type)
@@ -1768,14 +1684,16 @@ HRESULT WINAPI MFCreateMediaType(IMFMediaType **type)
if(!type)
return E_INVALIDARG;
@@ -373,5 +364,5 @@ index df61f3cdc9..744f074b56 100644
}
--
2.18.0
2.7.4

View File

@@ -1,4 +1,4 @@
From befe5cfba7094d1be9b71de2ea11b62de411fd7a Mon Sep 17 00:00:00 2001
From 7ddeecfd4195dc718f9a74aa5ccd2e3c6589f6b1 Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Fri, 24 Aug 2018 10:32:26 +1000
Subject: [PATCH 3/3] mfplat: Implement MFCreateSample
@@ -6,17 +6,17 @@ Subject: [PATCH 3/3] mfplat: Implement MFCreateSample
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=45617
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
dlls/mfplat/main.c | 445 +++++++++++++++++++++++++++++++++++++
dlls/mfplat/main.c | 445 +++++++++++++++++++++++++++++++++++++++++++++
dlls/mfplat/mfplat.spec | 2 +-
dlls/mfplat/tests/mfplat.c | 16 ++
dlls/mfplat/tests/mfplat.c | 17 ++
include/mfapi.h | 1 +
4 files changed, 463 insertions(+), 1 deletion(-)
4 files changed, 464 insertions(+), 1 deletion(-)
diff --git a/dlls/mfplat/main.c b/dlls/mfplat/main.c
index ce5d446bfb..5cc84a0566 100644
index 73bc564..771abb3 100644
--- a/dlls/mfplat/main.c
+++ b/dlls/mfplat/main.c
@@ -1919,3 +1919,448 @@ HRESULT WINAPI MFCreateStreamDescriptor(DWORD identifier, DWORD count,
@@ -2353,3 +2353,448 @@ HRESULT WINAPI MFCreateMemoryBuffer(DWORD max_length, IMFMediaBuffer **buffer)
return S_OK;
}
@@ -466,7 +466,7 @@ index ce5d446bfb..5cc84a0566 100644
+ return S_OK;
+}
diff --git a/dlls/mfplat/mfplat.spec b/dlls/mfplat/mfplat.spec
index a66f4d1817..0ad15a5f10 100644
index 42b0b86..c58233d 100644
--- a/dlls/mfplat/mfplat.spec
+++ b/dlls/mfplat/mfplat.spec
@@ -55,7 +55,7 @@
@@ -479,11 +479,11 @@ index a66f4d1817..0ad15a5f10 100644
@ stub MFCreateSocketListener
@ stdcall MFCreateSourceResolver(ptr)
diff --git a/dlls/mfplat/tests/mfplat.c b/dlls/mfplat/tests/mfplat.c
index f3a452179b..f5a3197d73 100644
index ccbbfb7..17cdc46 100644
--- a/dlls/mfplat/tests/mfplat.c
+++ b/dlls/mfplat/tests/mfplat.c
@@ -250,6 +250,21 @@ static void test_MFCreateAttributes(void)
IMFAttributes_Release(attributes);
@@ -363,6 +363,22 @@ static void test_MFCreateMemoryBuffer(void)
IMFMediaBuffer_Release(buffer);
}
+static void test_MFSample(void)
@@ -501,19 +501,20 @@ index f3a452179b..f5a3197d73 100644
+
+ IMFSample_Release(sample);
+}
+
START_TEST(mfplat)
{
@@ -261,6 +276,7 @@ START_TEST(mfplat)
CoInitialize(NULL);
@@ -373,6 +389,7 @@ START_TEST(mfplat)
test_source_resolver();
test_MFCreateMediaType();
test_MFCreateAttributes();
+ test_MFSample();
test_MFCreateMFByteStreamOnStream();
test_MFCreateMemoryBuffer();
CoUninitialize();
}
diff --git a/include/mfapi.h b/include/mfapi.h
index 5aead1e0bc..978726b358 100644
index 5b98187..45449b1 100644
--- a/include/mfapi.h
+++ b/include/mfapi.h
@@ -67,6 +67,7 @@ HRESULT WINAPI MFCancelWorkItem(MFWORKITEM_KEY key);
@@ -521,9 +522,9 @@ index 5aead1e0bc..978726b358 100644
HRESULT WINAPI MFCreateEventQueue(IMFMediaEventQueue **queue);
HRESULT WINAPI MFCreateMediaType(IMFMediaType **type);
+HRESULT WINAPI MFCreateSample(IMFSample **sample);
HRESULT WINAPI MFCreateMemoryBuffer(DWORD max_length, IMFMediaBuffer **buffer);
HRESULT WINAPI MFGetTimerPeriodicity(DWORD *periodicity);
HRESULT WINAPI MFTEnum(GUID category, UINT32 flags, MFT_REGISTER_TYPE_INFO *input_type,
MFT_REGISTER_TYPE_INFO *output_type, IMFAttributes *attributes,
--
2.18.0
2.7.4