Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mswasapi
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
External Wiki
External Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
BC
public
mswasapi
Commits
29cc41ea
Commit
29cc41ea
authored
Jul 17, 2020
by
Julien Wadel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove CoCreateInstance switch
parent
f58b2ec5
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
3 deletions
+5
-3
mswasapi.cpp
mswasapi.cpp
+3
-1
mswasapi_reader.cpp
mswasapi_reader.cpp
+1
-1
mswasapi_writer.cpp
mswasapi_writer.cpp
+1
-1
No files found.
mswasapi.cpp
View file @
29cc41ea
...
...
@@ -597,7 +597,9 @@ static void ms_wasapi_snd_card_detect_with_data_flow(MSSndCardManager *m, EDataF
#else
HRESULT
result
=
CoInitialize
(
NULL
);
#endif
result
=
CoCreateInstanceBT
(
CLSID_MMDeviceEnumerator
,
NULL
,
CLSCTX_ALL
,
IID_IMMDeviceEnumerator
,
(
void
**
)
&
pEnumerator
);
result
=
CoCreateInstance
(
CLSID_MMDeviceEnumerator
,
NULL
,
CLSCTX_ALL
,
IID_IMMDeviceEnumerator
,
(
void
**
)
&
pEnumerator
);
REPORT_ERROR
(
"mswasapi: Could not create an instance of the device enumerator"
,
result
);
result
=
pEnumerator
->
GetDefaultAudioEndpoint
(
data_flow
,
eCommunications
,
&
pEndpoint
);
if
(
result
==
S_OK
)
{
...
...
mswasapi_reader.cpp
View file @
29cc41ea
...
...
@@ -126,7 +126,7 @@ void MSWASAPIReader::init(LPCWSTR id)
#else
CoInitialize
(
NULL
);
#endif
result
=
CoCreateInstance
BT
(
CLSID_MMDeviceEnumerator
,
NULL
,
CLSCTX_ALL
,
IID_IMMDeviceEnumerator
,
(
void
**
)
&
pEnumerator
);
result
=
CoCreateInstance
(
CLSID_MMDeviceEnumerator
,
NULL
,
CLSCTX_ALL
,
IID_IMMDeviceEnumerator
,
(
void
**
)
&
pEnumerator
);
REPORT_ERROR
(
"mswasapi: Could not create an instance of the device enumerator"
,
result
);
mCaptureId
=
id
;
result
=
pEnumerator
->
GetDevice
(
mCaptureId
,
&
pDevice
);
...
...
mswasapi_writer.cpp
View file @
29cc41ea
...
...
@@ -126,7 +126,7 @@ void MSWASAPIWriter::init(LPCWSTR id, MSFilter *f) {
#else
CoInitialize
(
NULL
);
#endif
result
=
CoCreateInstance
BT
(
CLSID_MMDeviceEnumerator
,
NULL
,
CLSCTX_ALL
,
IID_IMMDeviceEnumerator
,
(
void
**
)
&
pEnumerator
);
result
=
CoCreateInstance
(
CLSID_MMDeviceEnumerator
,
NULL
,
CLSCTX_ALL
,
IID_IMMDeviceEnumerator
,
(
void
**
)
&
pEnumerator
);
REPORT_ERROR
(
"mswasapi: Could not create an instance of the device enumerator"
,
result
);
mRenderId
=
id
;
result
=
pEnumerator
->
GetDevice
(
mRenderId
,
&
pDevice
);
...
...
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