Changeset 95364 in vbox for trunk/src/VBox/Main/xml
- Timestamp:
- Jun 24, 2022 4:51:21 PM (3 years ago)
- svn:sync-xref-src-repo-rev:
- 151958
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/xml/Settings.cpp
r95338 r95364 4605 4605 // settings before 1.3 used lower case so make sure this is case-insensitive 4606 4606 strTemp.toUpper(); 4607 if (strTemp == "NULL") 4607 if (strTemp == "DEFAULT") 4608 aa.driverType = AudioDriverType_Default; 4609 else if (strTemp == "NULL") 4608 4610 aa.driverType = AudioDriverType_Null; 4611 else if (strTemp == "WAS") 4612 aa.driverType = AudioDriverType_WAS; 4609 4613 else if (strTemp == "WINMM") 4610 4614 aa.driverType = AudioDriverType_WinMM; … … 4621 4625 else if (strTemp == "COREAUDIO") 4622 4626 aa.driverType = AudioDriverType_CoreAudio; 4623 else if (strTemp == "MMPM") 4627 else if (strTemp == "MMPM") /* Deprecated; only kept for backwards compatibility. */ 4624 4628 aa.driverType = AudioDriverType_MMPM; 4625 4629 else … … 7314 7318 switch (hw.audioAdapter.driverType) 7315 7319 { 7320 case AudioDriverType_Default: pcszDriver = "Default"; break; 7316 7321 case AudioDriverType_WinMM: pcszDriver = "WinMM"; break; 7317 7322 case AudioDriverType_DirectSound: pcszDriver = "DirectSound"; break; 7323 case AudioDriverType_WAS: pcszDriver = "WAS"; break; 7324 case AudioDriverType_ALSA: pcszDriver = "ALSA"; break; 7325 case AudioDriverType_OSS: pcszDriver = "OSS"; break; 7326 case AudioDriverType_Pulse: pcszDriver = "Pulse"; break; 7327 case AudioDriverType_CoreAudio: pcszDriver = "CoreAudio"; break; 7318 7328 case AudioDriverType_SolAudio: pcszDriver = "SolAudio"; break; 7319 case AudioDriverType_ALSA: pcszDriver = "ALSA"; break;7320 case AudioDriverType_Pulse: pcszDriver = "Pulse"; break;7321 case AudioDriverType_OSS: pcszDriver = "OSS"; break;7322 case AudioDriverType_CoreAudio: pcszDriver = "CoreAudio"; break;7323 7329 case AudioDriverType_MMPM: pcszDriver = "MMPM"; break; 7324 7330 default: /*case AudioDriverType_Null:*/ pcszDriver = "Null"; break; … … 8236 8242 * the current host platform. For example, this would return false 8237 8243 * for AudioDriverType_DirectSound when compiled on a Linux host. 8238 * @param drv AudioDriverType_* enum to test. 8239 * @return true only if the current host supports that driver. 8244 * 8245 * @return \c true if the current host supports the driver, \c false if not. 8246 * @param enmDrvType AudioDriverType_* enum to test. 8240 8247 */ 8241 8248 /*static*/ 8242 bool MachineConfigFile::isAudioDriverAllowedOnThisHost(AudioDriverType_T drv) 8243 { 8244 switch (drv) 8245 { 8249 bool MachineConfigFile::isAudioDriverAllowedOnThisHost(AudioDriverType_T enmDrvType) 8250 { 8251 switch (enmDrvType) 8252 { 8253 case AudioDriverType_Default: 8254 RT_FALL_THROUGH(); 8246 8255 case AudioDriverType_Null: 8247 8256 #ifdef RT_OS_WINDOWS 8257 case AudioDriverType_WAS: 8258 /* We only support WAS on systems we tested so far (Vista+). */ 8259 if (RTSystemGetNtVersion() < RTSYSTEM_MAKE_NT_VERSION(6,1,0)) 8260 break; 8261 RT_FALL_THROUGH(); 8248 8262 case AudioDriverType_DirectSound: 8249 8263 #endif … … 8275 8289 * or ALSA are actually supported on the first call. 8276 8290 * 8291 * When more than one supported audio stack is available, choose the most suited 8292 * (probably newest in most cases) one. 8293 * 8277 8294 * @return Default audio driver type for this host platform. 8278 8295 */ … … 8281 8298 { 8282 8299 #if defined(RT_OS_WINDOWS) 8300 if (RTSystemGetNtVersion() >= RTSYSTEM_MAKE_NT_VERSION(6,1,0)) 8301 return AudioDriverType_WAS; 8283 8302 return AudioDriverType_DirectSound; 8284 8303 … … 8301 8320 if (RTLdrIsLoadable("libasound.so.2")) 8302 8321 s_enmLinuxDriver = AudioDriverType_ALSA; 8303 else8304 8322 # endif /* VBOX_WITH_AUDIO_ALSA */ 8305 s_enmLinuxDriver = AudioDriverType_OSS; 8323 # ifdef VBOX_WITH_AUDIO_OSS 8324 else 8325 s_enmLinuxDriver = AudioDriverType_OSS; 8326 # endif /* VBOX_WITH_AUDIO_OSS */ 8306 8327 } 8307 8328 return s_enmLinuxDriver;
Note:
See TracChangeset
for help on using the changeset viewer.