Questions tagged [winmm]

115 questions
24
votes
3 answers

Controlling Excel via Midi controller

I've got one of these (source: netdna-cdn.com) and wanted to use the sliders on it to control Excel, just like one of the Excel form control scroll bars. I've managed to modify this code for VBA, but it is extremely unstable. Can anyone help me…
user1938620
  • 341
  • 2
  • 5
10
votes
1 answer

NullReferenceException, no stack trace... where to start?

I have a WPF audio application. Occasionally (and even in the debugger) I'm seeing a NullReferenceException which carries no stack trace information with it. How can one start debugging such an issue? Some background: I'm P/Invoking functions in…
spender
  • 117,338
  • 33
  • 229
  • 351
7
votes
2 answers

Change program's volume on Win 7

I want to change the program's volume (and not master volume). I have the following code right now: DllImport("winmm.dll")] public static extern int waveOutGetVolume(IntPtr hwo, out uint dwVolume); [DllImport("winmm.dll")] public static extern int…
Devator
  • 3,686
  • 4
  • 33
  • 52
6
votes
0 answers

inconsistent midi naming when using multiple devices of the same type

I am facing an obscure behaviour of device naming when trying to use multiple USB midi devices of the same type of hardware. As this might be hardware/system/driver related, here is my general setup: host: Windows 8.1 x64 (tested on multiple…
mvo
  • 1,138
  • 10
  • 18
6
votes
1 answer

How to find the source of an 'Access Violation'

To put in a nutshell, I have a C# application doing lots of mciSendString calls ( via dllimport ) to control wav files playback ( essentially open, play, pause, stop, status, close ). And after running for a while, the application crashes without…
DarkUrse
  • 2,084
  • 3
  • 25
  • 33
5
votes
3 answers

multi channel sound with winmm, many WaveOutOpen?

I am trying to play a sound on Windows XP in multi-channel (parallel) manner. I had read somewhere that playing parallel sounds with WinMM is maybe not possible, but here is what I observe: When I call WaveOutOpen() once, and then call many…
grunge fightr
  • 1,360
  • 2
  • 19
  • 38
5
votes
2 answers

Create a virtual MIDI port

I want to create a virtual MIDI loopback cable program that creates virtual MIDI ports to interconnect applications on Windows that want to open hardware-MIDI-ports for communication. SOrry if I am not clear in my requirements, here is an example…
ashwnacharya
  • 14,601
  • 23
  • 89
  • 112
5
votes
1 answer

Lowest audio settings possible with winmm.dll mciSendString?

I'm attempting to set this recording to the lowest settings possible using C# and winmm.dll. I've set the settings below but I'm not hearing any difference. Does anyone know if I'm missing something? I'm trying to get the lowest audio settings…
Taurian
  • 1,660
  • 7
  • 20
  • 28
5
votes
4 answers

What determines the order for sound devices in windows when using winmm.dll?

I am trying to use NAudio to create a multiple sound output application. We have 8 USB sound cards installed. NAudio lets me use all 8 but I can't figure out a pattern for determining which device index is which card. The cards will be hooked up…
Robin Robinson
  • 1,595
  • 1
  • 20
  • 24
4
votes
3 answers

MIDIHDR Problems

I am trying to write a wrapper library for MIDI functions in WinMM.dll, but I am having trouble with MIDI long messages. I found this in PIvnoke.net (I added the first line myself): [StructLayout(LayoutKind.Sequential)] public struct MIDIHDR …
Mika
  • 111
  • 3
  • 10
4
votes
1 answer

midioutshortmsg no sound

So I'm trying to play single notes in C# using midiOutShortMsg(). The problem is that no sound is played. The one way I've figured out to play the note is by putting the midiOutShortMsg() in a for loop from i=0 to 10000. But I don't believe…
Shinsuke
  • 51
  • 3
4
votes
2 answers

How to use PlaySound in C

I am using code::blocks IDE which runs on GNU GCC compiler. In my project I want to play a .wav sound file in C. I tried to play a .wav sound file with a function called PlaySound. When I compiled the code code::blocks gave me an error - PlaySoundA…
Box Box Box Box
  • 5,094
  • 10
  • 49
  • 67
4
votes
3 answers

C#4.0 Issues playing .mp3 files over 192kbps using winmm.dll

MCIERR_INTERNALI am trying to make a simple Media player inside an app, but I've noticed that my code WILL NOT play music unless the file is a low bitrate around 192kbps or less. The issue is that most of my music is around 260-320kbps. Here's my…
Medic3000
  • 786
  • 4
  • 20
  • 44
4
votes
3 answers

Where can I find 'winmm.lib' (I'm using Visual Studio 2012)

My OS is 64Bit Windows 7. I wanted to build the DirectX Sample in C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Samples\C++\Direct3D10\Tutorials\Tutorial02. but when I build error occured with fatal error LNK1104: 'winmm.lib' can't open…
Se Cheol Park
  • 49
  • 1
  • 1
  • 3
4
votes
1 answer

Correct Windows API to find CurrentControlSet\Control\MediaProperties?

I'm looking to support a custom joystick device, and due to project requirements I can no longer use the DirectInput API. I've switched to using the "classic" Windows multimedia API (e.g. joyGetDevCaps and family), and it all works with one…
holtavolt
  • 4,378
  • 1
  • 26
  • 40
1
2 3 4 5 6 7 8