How to write a *.wav file to sound port in unmanaged c# or c++ so that it get play without using win32 API's ?
108454
#include "ALLOC.H"\n#include "DOS.H"\n#include "CONIO.H"\n#include "STDIO.H"\n\n\nvoid main()\n{\n char *name;\n printf(" Enter the file name...:");\n scanf("%s",name);\nplaywav(name,1.0);\n\n}\n\n\nvoid playwav(char wavefile[14],float delaytime);\nstruct WaveData {\n  unsigned int SoundLength, Frequency;\n  char *Sample;\n};\n\n\nstruct HeaderType {\n  long         RIFF;      //RIFF header\n  char         NI1 [18];  //not important\n\n  unsigned int Channels;  //channels 1 = mono; 2 = stereo\n  long         Frequency; //sample frequency\n  char         NI2 [6];   //not important\n  char         BitRes;    //bit resolution 8/16 bit\n  char         NI3 [12];  //not important\n} Header;\n\n\n\n\n\nstruct WaveData Voice;         //Pointer to wave file\n\n\nunsigned int    Base;          //Sound Blaster base address\n\n\nchar            WaveFile [25]; //File name for the wave file to be played\n\n\n/*************************************************************************\n***\n** Checks to see if a Sound Blaster exists at a given address, returns\n**\n** true if Sound Blaster found, false if not.\n**\n**************************************************************************\n**/\nint ResetDSP(unsigned int Test)\n{\n  //Reset the DSP\n  outportb (Test + 0x6, 1);\n  delay(10);\n  outportb (Test + 0x6, 0);\n  delay(10);\n  //Check if (reset was succesfull\n  if ((inportb(Test + 0xE) & 0x80 == 0x80) && (inportb(Test + 0xA) ==\n0xAA))\n  {\n    //DSP was found\n    Base = Test;\n    return (1);\n  }\n  else\n    //No DSP was found\n    return (0);\n}\n\n\n/*************************************************************************\n***\n** Send a byte to the DSP (Digital Signal Processor) on the Sound Blaster\n**\n**************************************************************************\n**/\nvoid WriteDSP(unsigned char Value)\n{\n  //Wait for the DSP to be ready to accept data\n  while ((inportb(Base + 0xC) & 0x80) == 0x80);\n  //Send byte\n\n  outportb (Base + 0xC, Value);\n}\n\n\n/*************************************************************************\n***\n** Plays a part of the memory\n**\n**************************************************************************\n**/\nvoid PlayBack (struct WaveData *Wave)\n{\n  long          LinearAddress;\n  unsigned int  Page, OffSet;\n  unsigned char TimeConstant;\n\n\n  TimeConstant = (65536 - (256000000 / Wave->Frequency)) >> 8;\n  WriteDSP(0x40);                  //DSP-command 40h - Set sample frequency\n  WriteDSP(TimeConstant);          //Write time constant\n\n\n  //Convert pointer to linear address\n  LinearAddress = FP_SEG (Wave->Sample);\n  LinearAddress = (LinearAddress << 4) + FP_OFF (Wave->Sample);\n  Page = LinearAddress >> 16;      //Calculate page\n  OffSet = LinearAddress & 0xFFFF; //Calculate offset in the page\n  /*\n      Note - this procedure only works with DMA channel 1\n  */\n  outportb (0x0A, 5);              //Mask DMA channel 1\n  outportb (0x0C, 0);              //Clear byte pointer\n  outportb (0x0B, 0x49);           //Set mode\n  /*\n      The mode consists of the following:\n      0x49 = binary 01 00 10 01\n                    |  |  |  |\n                    |  |  |  +- DMA channel 01\n                    |  |  +---- Read operation (the DSP reads from memory)\n                    |  +------- Single cycle mode\n                    +---------- Block mode\n  */\n\n\n  outportb (0x02, OffSet & 0x100); //Write the offset to the DMA controller\n  outportb (0x02, OffSet >> 8);\n\n\n  outportb (0x83, Page);           //Write the page to the DMA controller\n\n\n  outportb (0x03, Wave->SoundLength & 0x100);\n  outportb (0x03, Wave->SoundLength >> 8);\n\n\n  outportb (0x0A, 1);              //Unmask DMA channel\n\n\n\n  WriteDSP(0x14);                  // DSP-command 14h - Single cycle playback\n  WriteDSP(Wave->SoundLength & 0xFF);\n  WriteDSP(Wave->SoundLength
640464
You can use different programs to convert the sound file. One I have found that works well is Goldwave. However, the trial version only allows so many conversions before you have to buy the program.
736117
Description:\nmss32.dll is a module for the Miles Sound System Library used by WinAmp and other multimedia applications for audio playback and sound effects.\n\nPart Of:  WinAmp\nSystem DLL: No\n\nCommon Errors:  File Not Found, Missing File, Exception Errors
1085047
http://www.microsoft.com/whdc/device/audio/HDAudioDDI.mspx
137722
This is a very simple process.  Go to google and search "sound file converter".  There is a great amount of free programs designed for just his purpose.  I will give you a recommendation on a program once I find one, okay?  Please refrain from downloading until then.\n\nOn a different note, are you wanting to transfer them from the CD to the computer?  If so, email me and tell me what version of Windows Media Player you are running.
149258
I only have programs to go the other way around.  I configured Winamp to change midi files to wav files (I found out how on the interent), then I use audioconverter to change the wav file to mp3 (so that I can burn it on audio CD's.  Try either searching the internet for (use the quotes) "wav to midi", or go to www.download.com and browse for something there.
1173809
there is a program which called ( streambox ) it's so usefull and it can transfer wav to mp3 and so on .. search for it and download it ,, I tried that program it's exactly what u want..\n\nwith my best wishes ...............................  :-)
122414
/www.brokenvaporware.com/products/msgramp/  That's if I understood your question well,this program should make your status display the song you are listening in winamp
224591
Select Settings, then Control Panel. \n\nDouble-click the Sounds and Multimedia icon.\n\nClick the "Devices" tab\n\nClick on the plus-symbol (+) next to Audio Compression Codecs to expand the list of installed codecs. \n\nIf DSP Group TrueSpeech(TM) Audio CODEC is displayed, Double click on it and click "Remove" you will need to restart the computer at this point.\n\nIf DSP Group TrueSpeech(TM) Audio CODEC is not displayed, it needs to be installed.\n\nIn the Control Panel window, double-click the Add New Hardware icon\n\nPress the Next button. \n\nYou are asked whether to search for your new hardware. \n\nSelect No, then press the Next button. \n\nSelect Sound, video, and game controllers from the Hardware types and press the Next button. \n\nSelect DSP Group from the Manufacturers list and TrueSpeech(TM) Software CODEC from the Models list, then press the Next button. \n\nPress the Finish button. \n\nYou will be prompted to restart Windows. You may restart now or later, but the codec will not be available until you restart your computer. \n\nIf after restarting your computer and attempting to start a voice chat you are still receiving the same error message, continue to the next step. \n\nOpen the Multimedia Devices window as directed in steps 1-5. \n\nSelect DSP Group TrueSpeech(TM) Audio CODEC from the list of Multimedia Devices and press the Properties button.\n\nThe Properties window is displayed. \n\nVerify that Use this audio codec is selected, and press the OK button.
1073460
The easiest way to do it on the cheap side is with a program called AUDACITY. Audacity is an open source sound editor with some function of highend adio editing software. It isn't as feature packed as Adobe Audition or other commercial software but it will do for your question.\n\nDownload Audacity>\nhttp://audacity.sourceforge.net/\n\nInstall Audacity and open it.\n\nON the FILE menu, Select OPEN. point the program to the path of the sound you want to change to 44.1 Wav. It will open. Now at the bottem of Audacity you will see a box that says  PROJECT RATE, click on it and select 44100.\n\nNow goto FILE and select EXPORT AS WAV. a box appears,browse to where you want to save, change the filename  and click SAVE. Wait a few seconds it's done.\n\nAlternativly you can use winamp.\nDownload and install winamp (if you don't have it yet)\nhttp://www.winamp.com\n\nOpen it up.\nDrag and drop your file/s into the playlist editor. Goto OPTIONS and select PREFERENCES. In the Sub tree of the section marked PLUGINS, click on OUTPUT. Click on the NULLSOFT DISK WRITER PLUGIN and then click on the button CONFIGURE below. Change the Output directory. Check CONVERT TO FORMAT, select format PCM and attributes 44.100kHz,16 bit stereo and click OK. Click OK again and CLOSE. before you press play make sure repeat is disabled (the circle arrow thing must not have a light on).\n Click PLAY. winamp will now make all the tracks in your playlist editor into single files with the names of the files you selected.\n\nWhen your doen just go back to preferendes, Plugins > output and click on DIRECT SOUND OUTPUT and click CLOSE so that winamp will play normal.\n\nthere are 100's of programs that will work easier but most are trial versions.\n\nYou didn't give that much info about why you want to or from what kind of source you are working, so advice is limited. It isn't a good idea to upsample the rate say from 22 or 32 to 44.1, because it will introduce nosie which may be audible(best way i can describe it).
1038760
Windows Media Encoder 9, free too. I don't know if it will work in games though.
1183192
right click on ur text/image N go to "action settings" there u hav options like mouse click N mouse over.In tht select play sound. U can chose ur own .wmv sound too
1026747
Windows Audio Converter. It comes with Media Center Edition...if you have that...if not you can search audio converter on google and a ton of stuff comes up but...this is what I do...Where did you get your WMA? From a cd? Then put the cd back in and use Exact Audio Copy to make an uncompressed .wav then use Besweet GUI to turn it into a nice clean compact .mp3. ;) Sounds complicated but it's not and the sound is great. Plus they're both freeware!
626116
You should use respective library file (.dll) file. You can use it in your visual program to play your music file.
152254
I assume that you want to add sound to a VB6 application. Below is the code I use:\n\nYou need to add the Component called "Microsoft Multimedia Control 6.0 (SP3)" to your project. Then you just have to initialize and play the specified file. Here's the way I coded it:\n\nPublic Sub PlayWavFile(ByVal pFilename As String)\nMMControl1.Notify = False\nMMControl1.Wait = False\nMMControl1.Shareable = False\nMMControl1.DeviceType = "WaveAudio"\n' Set the file name.\nMMControl1.fileName = pFilename\n\n' Open the MCI device.\nMMControl1.Command = "Open"\nMMControl1.Command = "Play"\nEnd Sub\n\nYou call the function like this:\nPlayWavFile ("MyMusicFile.wav")\n\nThe control will play the following Multimedia types:\nAnimation - Plays animation \nCDAudio - Plays CD audio \nAVIVideo - Plays .AVI video files \nOverlay - Plays analog video \nSequencer - MIDI\nVideoDisc - Plays video discs \nWaveAudio - Plays .WAV sound files
1070539
There are many programs that appear as a plug-in for various players (such as RipStream for WinAMP). These can do it well, but aren't great. These pretty much record what is sent to your sound card as the audio is played.\n\nAnother method is to find a program to type the stream's URL into and let it download it for you. These cost money, and there are plenty around.\n\nThe most basic method is to find a sound recorder (Cool Edit Pro or Windows Sound Recorder, for example) and use that to record from "Wave" (the volume channel in the Volume Control).\n\nWhichever method you use, they can be searched for in most search engines.
250602
Step by Step in XP:\n1) Click the Start button\n2) Open Control Panel\n3) Open Sounds and Audio Devices\n4) Click the Sounds Tab\n5) Scroll down on the 'Program Events' window\n   until you see 'Windows Startup'  Click ONCE on that\n   to highlight it.\n6) Click the 'Browse' button\n7) Select the wave file you wish to use as your startup music/sound\n8) Click 'OK'\n9) Click 'Apply' and then 'OK'\n\nthat's it!  your start up music has been changed.