MCPcopy Create free account
hub / github.com/Aloshi/EmulationStation / deinit

Method deinit

src/VolumeControl.cpp:211–235  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

209}
210
211void VolumeControl::deinit()
212{
213 //deinitialize audio mixer interface
214#if defined (__APPLE__)
215 #error TODO: Not implemented for MacOS yet!!!
216#elif defined(__linux__)
217 if (mixerHandle != nullptr) {
218 snd_mixer_detach(mixerHandle, mixerCard);
219 snd_mixer_free(mixerHandle);
220 snd_mixer_close(mixerHandle);
221 mixerHandle = nullptr;
222 mixerElem = nullptr;
223 }
224#elif defined(WIN32) || defined(_WIN32)
225 if (mixerHandle != nullptr) {
226 mixerClose(mixerHandle);
227 mixerHandle = nullptr;
228 }
229 else if (endpointVolume != nullptr) {
230 endpointVolume->Release();
231 endpointVolume = nullptr;
232 CoUninitialize();
233 }
234#endif
235}
236
237int VolumeControl::getVolume() const
238{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected