

Where freq is the frequency in Hz and the duration. ' Create a DataStream with pinned managed bufferĭim ds = (sampleBuffer, True, True, 0, True)ĭim bu As New īu.LoopCount = 0 'īu.Flags = ĭim Amplitude As Double = (1 / Frequencies.Length)įor i As Integer = 0 To sampleBuffer.Length - 2 Step 2ĭim sampleTime As Double = totalTime / sampleRateįor y As Integer = 0 To Frequencies.Length - 1ĬurrentSample += Amplitude * Math.Sin(2 * Math.PI * Frequencies(y) * sampleTime) * Short. import winsound duration 1000 milliseconds freq 440 Hz winsound.Beep(freq, duration). Pick up Melodia for Windows Phone 8.1 here in the Store. ' Allocate 10s at 44.1Khz of stereo 16bit signalsĭim myBufferOfSamples = New Short(44100 * 10 * 2 - 1) Does anyone know where I might be able to find a download for the windows 8. Now, when an alert comes in for Facebook, WhatsApp or Twitter, you can have that unique and identifiable sound to go with it.

Any ideas? ' Initialization phase, keep this buffer during the life of your application

No sound comes out, but I think it's right. Following up on the topic presented here: Playing a sound from a generated buffer in a Windows 8 app, here's my attempted solution for Windows Phone 8.1, running in a simulator in Visual Studio 2015, in VB.NET attempting to implement SharpDX.XAudio2. I am attempting to generate a tone, for a set frequency and duration, on Windows Phone 8.1.
