Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-fonts
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
Aleksandr Isakov
wine-fonts
Commits
fd3c80b8
Commit
fd3c80b8
authored
May 30, 2019
by
Zebediah Figura
Committed by
Alexandre Julliard
May 31, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
quartz/dsoundrender: Use BaseFilterImpl_QueryInterface().
Signed-off-by:
Zebediah Figura
<
z.figura12@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
d930dff4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
37 deletions
+22
-37
dsoundrender.c
dlls/quartz/dsoundrender.c
+22
-37
No files found.
dlls/quartz/dsoundrender.c
View file @
fd3c80b8
...
...
@@ -611,6 +611,23 @@ static void dsound_render_destroy(BaseRenderer *iface)
CoTaskMemFree
(
filter
);
}
static
HRESULT
dsound_render_query_interface
(
BaseRenderer
*
iface
,
REFIID
iid
,
void
**
out
)
{
DSoundRenderImpl
*
filter
=
impl_from_BaseRenderer
(
iface
);
if
(
IsEqualGUID
(
iid
,
&
IID_IBasicAudio
))
*
out
=
&
filter
->
basicAudio
.
IBasicAudio_iface
;
else
if
(
IsEqualGUID
(
iid
,
&
IID_IReferenceClock
))
*
out
=
&
filter
->
IReferenceClock_iface
;
else
if
(
IsEqualGUID
(
iid
,
&
IID_IAMDirectSound
))
*
out
=
&
filter
->
IAMDirectSound_iface
;
else
return
E_NOINTERFACE
;
IUnknown_AddRef
((
IUnknown
*
)
*
out
);
return
S_OK
;
}
static
const
BaseRendererFuncTable
BaseFuncTable
=
{
DSoundRender_CheckMediaType
,
DSoundRender_DoRenderSample
,
...
...
@@ -632,6 +649,7 @@ static const BaseRendererFuncTable BaseFuncTable = {
DSoundRender_BeginFlush
,
DSoundRender_EndFlush
,
dsound_render_destroy
,
dsound_render_query_interface
,
};
HRESULT
DSoundRender_create
(
IUnknown
*
pUnkOuter
,
LPVOID
*
ppv
)
...
...
@@ -705,39 +723,6 @@ HRESULT DSoundRender_create(IUnknown * pUnkOuter, LPVOID * ppv)
return
hr
;
}
static
HRESULT
WINAPI
DSoundRender_QueryInterface
(
IBaseFilter
*
iface
,
REFIID
riid
,
LPVOID
*
ppv
)
{
DSoundRenderImpl
*
This
=
impl_from_IBaseFilter
(
iface
);
TRACE
(
"(%p, %p)->(%s, %p)
\n
"
,
This
,
iface
,
qzdebugstr_guid
(
riid
),
ppv
);
*
ppv
=
NULL
;
if
(
IsEqualIID
(
riid
,
&
IID_IBasicAudio
))
*
ppv
=
&
This
->
basicAudio
.
IBasicAudio_iface
;
else
if
(
IsEqualIID
(
riid
,
&
IID_IReferenceClock
))
*
ppv
=
&
This
->
IReferenceClock_iface
;
else
if
(
IsEqualIID
(
riid
,
&
IID_IAMDirectSound
))
*
ppv
=
&
This
->
IAMDirectSound_iface
;
else
{
HRESULT
hr
;
hr
=
BaseRendererImpl_QueryInterface
(
iface
,
riid
,
ppv
);
if
(
SUCCEEDED
(
hr
))
return
hr
;
}
if
(
*
ppv
)
{
IUnknown_AddRef
((
IUnknown
*
)(
*
ppv
));
return
S_OK
;
}
if
(
!
IsEqualIID
(
riid
,
&
IID_IPin
)
&&
!
IsEqualIID
(
riid
,
&
IID_IVideoWindow
))
FIXME
(
"No interface for %s!
\n
"
,
qzdebugstr_guid
(
riid
));
return
E_NOINTERFACE
;
}
static
HRESULT
WINAPI
DSoundRender_Pause
(
IBaseFilter
*
iface
)
{
DSoundRenderImpl
*
This
=
impl_from_IBaseFilter
(
iface
);
...
...
@@ -770,7 +755,7 @@ static HRESULT WINAPI DSoundRender_Pause(IBaseFilter * iface)
static
const
IBaseFilterVtbl
DSoundRender_Vtbl
=
{
DSoundRender
_QueryInterface
,
BaseFilterImpl
_QueryInterface
,
BaseFilterImpl_AddRef
,
BaseFilterImpl_Release
,
BaseFilterImpl_GetClassID
,
...
...
@@ -795,7 +780,7 @@ static HRESULT WINAPI Basicaudio_QueryInterface(IBasicAudio *iface,
TRACE
(
"(%p/%p)->(%s, %p)
\n
"
,
This
,
iface
,
debugstr_guid
(
riid
),
ppvObj
);
return
DSoundRender
_QueryInterface
(
&
This
->
renderer
.
filter
.
IBaseFilter_iface
,
riid
,
ppvObj
);
return
BaseFilterImpl
_QueryInterface
(
&
This
->
renderer
.
filter
.
IBaseFilter_iface
,
riid
,
ppvObj
);
}
static
ULONG
WINAPI
Basicaudio_AddRef
(
IBasicAudio
*
iface
)
{
...
...
@@ -989,7 +974,7 @@ static HRESULT WINAPI ReferenceClock_QueryInterface(IReferenceClock *iface,
TRACE
(
"(%p/%p)->(%s, %p)
\n
"
,
This
,
iface
,
debugstr_guid
(
riid
),
ppvObj
);
return
DSoundRender
_QueryInterface
(
&
This
->
renderer
.
filter
.
IBaseFilter_iface
,
riid
,
ppvObj
);
return
BaseFilterImpl
_QueryInterface
(
&
This
->
renderer
.
filter
.
IBaseFilter_iface
,
riid
,
ppvObj
);
}
static
ULONG
WINAPI
ReferenceClock_AddRef
(
IReferenceClock
*
iface
)
...
...
@@ -1157,7 +1142,7 @@ static HRESULT WINAPI AMDirectSound_QueryInterface(IAMDirectSound *iface,
TRACE
(
"(%p/%p)->(%s, %p)
\n
"
,
This
,
iface
,
debugstr_guid
(
riid
),
ppvObj
);
return
DSoundRender
_QueryInterface
(
&
This
->
renderer
.
filter
.
IBaseFilter_iface
,
riid
,
ppvObj
);
return
BaseFilterImpl
_QueryInterface
(
&
This
->
renderer
.
filter
.
IBaseFilter_iface
,
riid
,
ppvObj
);
}
static
ULONG
WINAPI
AMDirectSound_AddRef
(
IAMDirectSound
*
iface
)
...
...
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