Questions tagged [mcisendstring]

The mciSendString function sends a command string to an MCI device. The device that the command is sent to is specified in the command string.

48 questions
5
votes
1 answer

mciSendString doesn't pause sound played from a thread

Recently I already asked for a solution similar to this questions: Is there a way to pause/stop a mp3 file playing with mcisendstring with the "wait" option? I want to implement a function in my audio player which allows people to have sound playing…
Sossenbinder
  • 4,852
  • 5
  • 35
  • 78
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
3
votes
2 answers

Playing mp3 files with mciSendString (MCIERR_CANNOT_LOAD_DRIVER)

I am trying to write some code that can play an .mp3 file. I thought I could use the mciSendString call, but I am getting a strange error. So, when I have this code: int rc=mciSendString(L"open songname.mp3 alias song1", NULL, 0, 0); rc returns…
patfam
  • 31
  • 2
2
votes
2 answers

How to specify a sound card for use with mciSendString API

I am updating an old VB6 app. Back in the day, I coded a wrapper around the mciSendString command to be able to record and playback audio. Back then, computers typically had a single audio card. Now, many of the customers have multiple sound…
AngryHacker
  • 59,598
  • 102
  • 325
  • 594
2
votes
2 answers

C# ISynchronizeInvoke Question

At the risk of sounding like a total noob, how do I implement ISynchronizeInvoke on a System.Timers.Timer? I have a class (no UI) that is making calls to mciSendString. I have a timer that is supposed to poll for the current status. All of the…
Krakerjak
  • 449
  • 3
  • 7
  • 17
2
votes
1 answer

Is there a way to pause/stop a mp3 file playing with mcisendstring with the "wait" option?

I am currently trying to create an mp3 player with the commands offered in this answer. Actually it's working pretty great, but right now I am trying to implement a continuos play with mciSendString("play mp3 wait", NULL, 0, NULL); This command is…
Sossenbinder
  • 4,852
  • 5
  • 35
  • 78
2
votes
1 answer

Using mciSendString with spaces

i am trying to play a sound file with spaces in its name example: "my File.wav" So sending files like this: mciSendString("play C:\\myFile.wav",0,0,0); will work just fine. but: mciSendString("play C:\\my File.wav",0,0,0); will fail. is there any…
Eran
  • 81
  • 1
  • 6
2
votes
1 answer

Opening shareable Midi synth device

this is my first post here, so I hope I won't screw it up. I am creating a twink of guitar hero as a console app in vb.net (homework) and I have ran into some problems. I am using CarlsMidiTools to pass parsed note values to synth. But I also want…
Lucause
  • 113
  • 1
  • 1
  • 7
1
vote
1 answer

How to play mp4 videos using MCI device

Using the mciSendString command I am able to play avi, mpeg, mp3, etc. but I am unable to play mp4. Here in this web-site it says I can play any videos provided that I have the correct codecs. I am able to play mp4 using my other media players (eg.…
Failed_Noob
  • 1,347
  • 18
  • 51
  • 67
1
vote
1 answer

How to put other controls on top of the video?

I am using mciSendString to play a video but I am unable to put any control like labels or buttons on top of the video. How do I put another control on top of the video ? Below is the code: Public Class Form1 Private Declare Function mciSendString…
Failed_Noob
  • 1,347
  • 18
  • 51
  • 67
1
vote
1 answer

Is there a way to use custom soundfonts/soundbanks with winmm?

Is there a way to use custom soundfonts/soundbanks while playing MIDI files with winmm.dll or do I have to use something else to do that? (I'm trying to do it in FASM).
fasm14
  • 43
  • 5
1
vote
0 answers

Why is relative path to audio file not working with subfolder?

I'm working on a project in VSCode and my folder configuration is currently laid out as the following: workspaceFolder bin src resources music When I build the project I have it specified in the tasks.json file as below: { "version":…
Xyr0
  • 11
  • 3
1
vote
0 answers

Playing multiple sounds simultaneously using mciSendString in Visual Studio (c#)

To make it clear: i tried to find a solution by looking at other posts in this forum but without effect (maybe because of my still weak knowledge of programming in c#). I am currently developing an RTS game. Like games do - they make…
Mariusz
  • 45
  • 1
  • 10
1
vote
1 answer

Detect Silence from Microphone

Using mcisendstring, I want to stop recording if a silence period (no input from microphone) is reached. I understand a timer would be involved, so after x seconds a check needs to be made, but what to check exactly? Currently,I record using: i =…
NoChance
  • 5,632
  • 4
  • 31
  • 45
1
vote
1 answer

mciSendString: file that contains spaces

If i use mciSendString (winmm.dll) and try to read file that contains spaces (for example F:\MUSIC\(01) [VA]01.StimAxel - Restart(DJ X-VenomRemix).mp3) i got an error with code 263. mciSendString can't work with files that contains spaces. How to…
Sergey
  • 105
  • 1
  • 2
  • 5
1
2 3 4