Ignore:
Timestamp:
Jan 14, 2013, 1:38:08 PM (9 years ago)
Author:
roman
Message:

Added signal frequency command line parameter

Location:
trunk/Utilities/LowLatencyWaveOutPlay
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Utilities/LowLatencyWaveOutPlay/LowLatencyWaveOutPlay.cpp

    r162 r164  
    5757        if(argc <= 3)
    5858        {
    59                 _tprintf(_T("Syntax: LowLatencyWaveOutPlay <sampling-rate> <buffer-count> <buffer-length>\n"));
     59                _tprintf(_T("Syntax: LowLatencyWaveOutPlay <sampling-rate> <buffer-count> <buffer-length> [<signal-frequency>]\n"));
    6060                _tprintf(_T("        Run 'LowLatencyWaveOutPlay 22050 8 5' to play 1000 Hz signal using 5 buffers, 8 ms long each via default audio output device (at 22050 Hz sampling rate)\n"));
    6161                return 1;
     
    7171        g_nBufferCount = _ttoi(argv[2]);
    7272        g_nBufferLength = _ttoi(argv[3]);
     73        if(argc > 4)
     74                g_nFrequency = _ttoi(argv[4]);
    7375        HWAVEOUT hWaveOut = NULL;
    7476        Check(waveOutOpen(&hWaveOut, WAVE_MAPPER, &g_WaveFormatEx, (DWORD_PTR) &waveOutProc, NULL, CALLBACK_FUNCTION));
Note: See TracChangeset for help on using the changeset viewer.