Author Topic: problems loading files with rare characters.  (Read 103 times)

valgaba

  • Posts: 4
Greetings, I have problems loading files with rare characters.


The first file, the mp3, works perfectly, but the wav does not have strange characters...
How could it be solved, I'm using C++ and QT


 
Code: [Select]
//            url="12.mp3"; //perfect
              url="iwhiteboard学科.wav"; //error

 HSTREAM stream=BASS_StreamCreateFile(FALSE, url.toLatin1(), 0, 0, BASS_STREAM_AUTOFREE);
 BASS_ChannelPlay(stream, false);


Thank you

Chris

  • Posts: 2115
Re: problems loading files with rare characters.
« Reply #1 on: 11 Jan '23 - 12:54 »
Hi, you can try this

Code: [Select]
HSTREAM stream=BASS_StreamCreateFile(FALSE, url, 0, 0, BASS_UNICODE | BASS_STREAM_AUTOFREE);
« Last Edit: 11 Jan '23 - 21:06 by Chris »

saga

  • Posts: 2642
Re: problems loading files with rare characters.
« Reply #2 on: 11 Jan '23 - 18:02 »
Almost...
Code: [Select]
HSTREAM stream=BASS_StreamCreateFile(FALSE, url.utf16(), 0, 0, BASS_UNICODE | BASS_STREAM_AUTOFREE);