cannot convert parameter 1 from 'char *' to 'LPCWSTR'

前端 未结 5 914
北海茫月
北海茫月 2020-12-15 06:45

Im trying to load a BMP file

AUX_RGBImageRec *LoadBMP(char *Filename)  // Loads A Bitmap Image
{
    FILE *File=NULL;                      // File Handle

           


        
5条回答
  •  悲&欢浪女
    2020-12-15 07:00

    You have a few options:

    • Change the 'character set' option in your project settings from 'Unicode' to 'Not Set'
    • Call auxDIBImageLoadA instead of auxDIBImageLoad
    • Change Filename's type from char* to wchar_t*
    • Use std::mbstowcs to convert Filename from a char* to a wchar_t*

提交回复
热议问题