我正在製作一個遊戲,我試圖用mciSendString()循環一個MIDI文件。我看過CProgramming.com,但該例子的窗口對象是OWL,我無法移植它們。我也嘗試着看Brian Gradin的問題,但答案只包含兩行代碼。我在MSDN上看過,但這就像一個參考,而不是一個教程。添加重複不會播放任何內容。這是我到目前爲止的代碼: mciSendString("open PUG1.MID typ
我想從C#中的.mp3文件中爲音頻播放器檢索詳細信息。 代碼剪斷: [DllImport("winmm.dll")]
private static extern long mciSendString(string strCommand, StringBuilder strReturn, int iReturnLength, IntPtr hwndCallback);
public stat
的輸出MIDI設備 所以,我終於找到了帖子中的一個,幫助我走出這個類 using System;
using System.Text;
using System.Runtime.InteropServices;
using System.IO;
namespace MidiProgram
{
/// <summary>
/// MCIPlayer is based off code