mci

MP3 playing using mci send string c++

有些话、适合烂在心里 提交于 2019-12-06 08:45:58
I'm trying to play some mp3 files as my background music in one of my project which Im doing. I tried to play it using mcisendstring but it just couldnt work :( These what I have done: CMP3_MCI myMp3; std::string address= "C:\\Users\\music embed testing\\test.mp3"; myMp3.Load(address); myMp3.Play(); //Load function void Load(string szFileName) { m_szFileName = szFileName; Load2(); } //load2 function void Load2() { std::string szCommand = "open \"" + GetFileName() + "\" type mpegvideo alias " + GetFileName(); mciSendString(szCommand.c_str(), NULL, 0, 0); } //play function void Play() { std:

Playback 24bit audio not possible

有些话、适合烂在心里 提交于 2019-12-05 03:02:00
I'm trying to play a 24bit audio file with my AutoHotkey app. It just uses SoundPlay . Windows 7 has no problem, however Windows XP users cannot play the 24bit files. The documentation says: All Windows OSes should be able to play .wav files. However, other files (.mp3, .avi, etc.) might not be playable if the right codecs or features aren't installed on the OS. Possible fixes mentioned in the article How to play 24bit WAV files in Windows Media Player are fixing the problem for Windows Media Player, however but not for autohotkey: Step-by-step guide Download Legacy HD Audio Filter regsvr32

Simplest way to play mp3 from Visual C++

牧云@^-^@ 提交于 2019-11-30 09:41:38
A few years back, I wrote some util library around DShow/DSound to let me play MP3s in a Windows C++ application. Is that still the normal way to do it in a C++/MFC app, or is that an area of DirectX that has been subsumed into the general Windows APIs? The motivation is simply we use the standard Windows PlaySound method for WAVs, and would like to be able to play MP3s using a similarly simple API, either provided by Windows or something we write to wrap more complex functionality. EDIT: this is for a large, commercial, closed-source project. And we only want to play things simply, paying a

Simplest way to play mp3 from Visual C++

五迷三道 提交于 2019-11-29 15:11:41
问题 A few years back, I wrote some util library around DShow/DSound to let me play MP3s in a Windows C++ application. Is that still the normal way to do it in a C++/MFC app, or is that an area of DirectX that has been subsumed into the general Windows APIs? The motivation is simply we use the standard Windows PlaySound method for WAVs, and would like to be able to play MP3s using a similarly simple API, either provided by Windows or something we write to wrap more complex functionality. EDIT:

How to change default sound playback device programmatically?

纵然是瞬间 提交于 2019-11-27 11:51:15
How to change the default default audio device for playback and recording in vista programmatically ? Is there any registry setting for it like sound manager in window XP? Which API does it? There is no public API which allows you to change the default audio device, that is functionality that is considered to be under the users control. This has always been the case in Windows. Having said that, if you search the web, there are a number of people who have reverse engineered the APIs that are used in Windows Vista to do this, but I'm not going to point you to them (the reverse engineered APIs