Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
f9ba9999
Commit
f9ba9999
authored
May 08, 2012
by
Christian Costa
Committed by
Alexandre Julliard
May 09, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dmsynth: Add stubbed IKsControl interface to DirectMusicSynthSink object.
parent
3c353607
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
69 additions
and
1 deletion
+69
-1
dmsynth_private.h
dlls/dmsynth/dmsynth_private.h
+1
-0
synthsink.c
dlls/dmsynth/synthsink.c
+67
-0
dmsynth.c
dlls/dmsynth/tests/dmsynth.c
+1
-1
No files found.
dlls/dmsynth/dmsynth_private.h
View file @
f9ba9999
...
...
@@ -75,6 +75,7 @@ struct IDirectMusicSynth8Impl {
struct
IDirectMusicSynthSinkImpl
{
/* IUnknown fields */
IDirectMusicSynthSink
IDirectMusicSynthSink_iface
;
IKsControl
IKsControl_iface
;
LONG
ref
;
/* IDirectMusicSynthSinkImpl fields */
...
...
dlls/dmsynth/synthsink.c
View file @
f9ba9999
...
...
@@ -41,6 +41,12 @@ static HRESULT WINAPI IDirectMusicSynthSinkImpl_QueryInterface(LPDIRECTMUSICSYNT
*
ppobj
=
This
;
return
S_OK
;
}
else
if
(
IsEqualIID
(
riid
,
&
IID_IKsControl
))
{
IUnknown_AddRef
(
iface
);
*
ppobj
=
&
This
->
IKsControl_iface
;
return
S_OK
;
}
WARN
(
"(%p, %s, %p): not found
\n
"
,
This
,
debugstr_dmguid
(
riid
),
ppobj
);
return
E_NOINTERFACE
;
}
...
...
@@ -168,6 +174,66 @@ static const IDirectMusicSynthSinkVtbl DirectMusicSynthSink_Vtbl = {
IDirectMusicSynthSinkImpl_GetDesiredBufferSize
};
static
inline
IDirectMusicSynthSinkImpl
*
impl_from_IKsControl
(
IKsControl
*
iface
)
{
return
CONTAINING_RECORD
(
iface
,
IDirectMusicSynthSinkImpl
,
IKsControl_iface
);
}
static
HRESULT
WINAPI
DMSynthSinkImpl_IKsControl_QueryInterface
(
IKsControl
*
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
IDirectMusicSynthSinkImpl
*
This
=
impl_from_IKsControl
(
iface
);
return
IDirectMusicSynthSinkImpl_QueryInterface
(
&
This
->
IDirectMusicSynthSink_iface
,
riid
,
ppobj
);
}
static
ULONG
WINAPI
DMSynthSinkImpl_IKsControl_AddRef
(
IKsControl
*
iface
)
{
IDirectMusicSynthSinkImpl
*
This
=
impl_from_IKsControl
(
iface
);
return
IDirectMusicSynthSinkImpl_AddRef
(
&
This
->
IDirectMusicSynthSink_iface
);
}
static
ULONG
WINAPI
DMSynthSinkImpl_IKsControl_Release
(
IKsControl
*
iface
)
{
IDirectMusicSynthSinkImpl
*
This
=
impl_from_IKsControl
(
iface
);
return
IDirectMusicSynthSinkImpl_Release
(
&
This
->
IDirectMusicSynthSink_iface
);
}
static
HRESULT
WINAPI
DMSynthSinkImpl_IKsControl_KsProperty
(
IKsControl
*
iface
,
PKSPROPERTY
Property
,
ULONG
PropertyLength
,
LPVOID
PropertyData
,
ULONG
DataLength
,
ULONG
*
BytesReturned
)
{
FIXME
(
"(%p)->(%p, %u, %p, %u, %p): stub
\n
"
,
iface
,
Property
,
PropertyLength
,
PropertyData
,
DataLength
,
BytesReturned
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
DMSynthSinkImpl_IKsControl_KsMethod
(
IKsControl
*
iface
,
PKSMETHOD
Method
,
ULONG
MethodLength
,
LPVOID
MethodData
,
ULONG
DataLength
,
ULONG
*
BytesReturned
)
{
FIXME
(
"(%p)->(%p, %u, %p, %u, %p): stub
\n
"
,
iface
,
Method
,
MethodLength
,
MethodData
,
DataLength
,
BytesReturned
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
DMSynthSinkImpl_IKsControl_KsEvent
(
IKsControl
*
iface
,
PKSEVENT
Event
,
ULONG
EventLength
,
LPVOID
EventData
,
ULONG
DataLength
,
ULONG
*
BytesReturned
)
{
FIXME
(
"(%p)->(%p, %u, %p, %u, %p): stub
\n
"
,
iface
,
Event
,
EventLength
,
EventData
,
DataLength
,
BytesReturned
);
return
E_NOTIMPL
;
}
static
const
IKsControlVtbl
DMSynthSinkImpl_IKsControl_Vtbl
=
{
DMSynthSinkImpl_IKsControl_QueryInterface
,
DMSynthSinkImpl_IKsControl_AddRef
,
DMSynthSinkImpl_IKsControl_Release
,
DMSynthSinkImpl_IKsControl_KsProperty
,
DMSynthSinkImpl_IKsControl_KsMethod
,
DMSynthSinkImpl_IKsControl_KsEvent
};
/* for ClassFactory */
HRESULT
WINAPI
DMUSIC_CreateDirectMusicSynthSinkImpl
(
LPCGUID
riid
,
LPVOID
*
ret_iface
,
LPUNKNOWN
unkouter
)
{
...
...
@@ -183,6 +249,7 @@ HRESULT WINAPI DMUSIC_CreateDirectMusicSynthSinkImpl(LPCGUID riid, LPVOID* ret_i
return
E_OUTOFMEMORY
;
obj
->
IDirectMusicSynthSink_iface
.
lpVtbl
=
&
DirectMusicSynthSink_Vtbl
;
obj
->
IKsControl_iface
.
lpVtbl
=
&
DMSynthSinkImpl_IKsControl_Vtbl
;
obj
->
ref
=
0
;
hr
=
CoCreateInstance
(
&
CLSID_SystemClock
,
NULL
,
CLSCTX_INPROC_SERVER
,
&
IID_IReferenceClock
,
(
LPVOID
*
)
&
obj
->
latency_clock
);
...
...
dlls/dmsynth/tests/dmsynth.c
View file @
f9ba9999
...
...
@@ -53,7 +53,7 @@ static void test_dmsynth(void)
hr
=
IDirectMusicSynth_QueryInterface
(
dmsynth
,
&
IID_IKsControl
,
(
LPVOID
*
)
&
control_synth
);
ok
(
hr
==
S_OK
,
"IDirectMusicSynth_QueryInterface returned: %x
\n
"
,
hr
);
hr
=
IDirectMusicSynthSink_QueryInterface
(
dmsynth_sink
,
&
IID_IKsControl
,
(
LPVOID
*
)
&
control_sink
);
todo_wine
ok
(
hr
==
S_OK
,
"IDirectMusicSynthSink_QueryInterface returned: %x
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"IDirectMusicSynthSink_QueryInterface returned: %x
\n
"
,
hr
);
/* Synth has no default clock */
hr
=
IDirectMusicSynth_GetLatencyClock
(
dmsynth
,
&
clock_synth
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment