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
26011d2d
Commit
26011d2d
authored
May 11, 2017
by
Michael Stefaniuc
Committed by
Alexandre Julliard
May 11, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dmime: Do not use Init() from InitAudio().
Signed-off-by:
Michael Stefaniuc
<
mstefani@winehq.org
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
3a145ac9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
8 deletions
+17
-8
performance.c
dlls/dmime/performance.c
+17
-8
No files found.
dlls/dmime/performance.c
View file @
26011d2d
...
...
@@ -892,17 +892,30 @@ static HRESULT WINAPI IDirectMusicPerformance8Impl_RhythmToTime(IDirectMusicPerf
/* IDirectMusicPerformance8 Interface part follow: */
static
HRESULT
WINAPI
IDirectMusicPerformance8Impl_InitAudio
(
IDirectMusicPerformance8
*
iface
,
IDirectMusic
**
ppDirectM
usic
,
IDirectSound
**
dsound
,
HWND
hwnd
,
IDirectMusic
**
dm
usic
,
IDirectSound
**
dsound
,
HWND
hwnd
,
DWORD
dwDefaultPathType
,
DWORD
dwPChannelCount
,
DWORD
dwFlags
,
DMUS_AUDIOPARAMS
*
pParams
)
{
IDirectMusicPerformance8Impl
*
This
=
impl_from_IDirectMusicPerformance8
(
iface
);
HRESULT
hr
=
S_OK
;
TRACE
(
"(%p, %p, %p, %p, %x, %u, %x, %p)
\n
"
,
This
,
ppDirectMusic
,
dsound
,
hwnd
,
dwDefaultPathType
,
dwPChannelCount
,
dwFlags
,
pParams
);
TRACE
(
"(%p, %p, %p, %p, %x, %u, %x, %p)
\n
"
,
This
,
dmusic
,
dsound
,
hwnd
,
dwDefaultPathType
,
dwPChannelCount
,
dwFlags
,
pParams
);
if
(
This
->
dmusic
)
return
DMUS_E_ALREADY_INITED
;
if
(
!
dmusic
||
!*
dmusic
)
{
hr
=
CoCreateInstance
(
&
CLSID_DirectMusic
,
NULL
,
CLSCTX_INPROC_SERVER
,
&
IID_IDirectMusic8
,
(
void
**
)
&
This
->
dmusic
);
if
(
FAILED
(
hr
))
return
hr
;
if
(
dmusic
)
*
dmusic
=
(
IDirectMusic
*
)
This
->
dmusic
;
}
else
This
->
dmusic
=
(
IDirectMusic8
*
)
*
dmusic
;
if
(
dmusic
)
IDirectMusic8_AddRef
(
This
->
dmusic
);
if
(
!
dsound
||
!*
dsound
)
{
hr
=
DirectSoundCreate8
(
NULL
,
(
IDirectSound8
**
)
&
This
->
dsound
,
NULL
);
if
(
FAILED
(
hr
))
...
...
@@ -913,12 +926,8 @@ static HRESULT WINAPI IDirectMusicPerformance8Impl_InitAudio(IDirectMusicPerform
*
dsound
=
This
->
dsound
;
}
else
This
->
dsound
=
*
dsound
;
IDirectMusicPerformance8_Init
(
iface
,
ppDirectMusic
,
This
->
dsound
,
hwnd
);
/* Init increases the ref count of the dsound object. Decrement it if the app doesn't want a pointer to the object. */
if
(
!
dsound
)
IDirectSound_Release
(
This
->
dsound
);
if
(
dsound
)
IDirectSound_AddRef
(
This
->
dsound
);
/* as seen in msdn we need params init before audio path creation */
if
(
NULL
!=
pParams
)
{
...
...
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