对于相应的头文件,库文件我好像都加了,可是还是有错。怎么回事啊。大家帮我看看BOOL GetFilterDescription 

    LPWAVEFILTER  pwfltr, 
    LPTSTR        pszFilterTag, 
    LPTSTR        pszFilter 


    MMRESULT      mmr; 
 
    // Retrieve the name for the filter tag of the specified filter. 
    if (NULL != pszFilterTag) { 
        ACMFILTERTAGDETAILS aftd; 
 
        // Initialize all unused members of the ACMFILTERTAGDETAILS 
        // structure to zero. 
        memset(&aftd, 0, sizeof(aftd)); 
 
        // Fill in the required members of the ACMFILTERTAGDETAILS 
        // structure for the ACM_FILTERTAGDETAILSF_FILTERTAG query. 
        aftd.cbStruct = sizeof(aftd); 
        aftd.dwFilterTag = pwfltr->dwFilterTag; 
 
        // Ask the ACM to find the first available driver that 
        // supports the specified filter tag. 
        mmr = acmFilterTagDetails(NULL, &aftd, 
            ACM_FILTERTAGDETAILSF_FILTERTAG); 
        if (MMSYSERR_NOERROR != mmr) { 
            // No ACM driver is available that supports the 
            // specified filter tag. 
            return (FALSE); 
        } 
 
        // Copy the filter tag name into the calling application's 
        // buffer. 
        lstrcpy(pszFilterTag, aftd.szFilterTag); 
    } 
 
    // Retrieve the description of the attributes for the specified 
    // filter. 
    if (NULL != pszFilter) { 
        ACMFILTERDETAILS afd; 
 
        // Initialize all unused members of the ACMFILTERDETAILS 
        // structure to zero. 
        memset(&afd, 0, sizeof(afd)); 
 
        // Fill in the required members of the ACMFILTERDETAILS 
        // structure for the ACM_FILTERDETAILSF_FILTER query. 
        afd.cbStruct    = sizeof(afd); 
        afd.dwFilterTag = pwfltr->dwFilterTag; 
        afd.pwfltr      = pwfltr; 
        afd.cbwfltr     = pwfltr->cbStruct; 
 
        // Ask the ACM to find the first available driver that 
        // supports the specified filter. 
        mmr = acmFilterDetails(NULL, &afd, ACM_FILTERDETAILSF_FILTER); 
        if (MMSYSERR_NOERROR != mmr) { 
            // No ACM driver is available that supports the 
            // specified filter. 
            return (FALSE); 
        } 
 
        // Copy the filter attributes description into the calling 
        // application's buffer. 
        lstrcpy(pszFilter, afd.szFilter); 
    } 
 
    return (TRUE); 

 

解决方案 »

  1.   

    呵呵, 正常, 删了重来, 我还有用CString时编译错的呢而且是头天编译对, 第二天错的, 中间没改代码, 晕吧?盗版本, 呵呵多试试吧, 还有你自己定义什么问题的, 一个个排除, step by step
      

  2.   

    你们到底懂不懂,能不能编译这行代码阿。
    我想你们把这行代码copy过去,然后编译一下,就知道我为什么问这个问题了。也不用问那么多。这样不是很麻烦吧,总比你们说一些无用的建议好吧。
    谢绝无任何建设性的回复。
      

  3.   

    三个头文件一个库文件Msacm32.lib
    #include "MMREG.H"
    #include "MMSYSTEM.H"
    #include "MSACM.H"
      

  4.   

    最后一个错误了
    d:\vcStudy\kk\MainFrm.h(46): error C2061: 语法错误 : 标识符“LPWAVEFILTER”怎么解决!!!!!
      

  5.   

    你的LPWAVEFILTER区缺少头文件加上#include "MMREG.H"
    #include "MMSYSTEM.H"
    #include "MSACM.H"
    应该可以
      

  6.   

    Msacm32.lib
    #include "MMREG.H"
    #include "MMSYSTEM.H"
    #include "MSACM.H"我用了这几个文件,编译正常,你把错误贴出来嘛
      

  7.   

    最后一个错误了
    d:\vcStudy\kk\MainFrm.h(46): error C2061: 语法错误 : 标识符“LPWAVEFILTER”要有mmreg.h顺便看看你的mmreg.h中有没有以下定义
    typedef WAVEFILTER FAR  *LPWAVEFILTER;