QSound()::isAvailable false on N900
Hi Folks,
this should prolly best be filed as bug - this code returns false:
[CODE] QFile file1(QDir::tempPath() + "/bgm.wav");
qDebug() << QDir::tempPath() + "/bgm.wav";
if (file1.open(QIODevice::ReadWrite))
{
// file.fileName() returns the unique file name
QFile workFile(":/sfx/rsc/music/bgm.wav");
if(workFile.open(QIODevice::ReadOnly))
{
file1.write(workFile.readAll());
workFile.close();
}
file1.close();
}
qDebug() << QSound::isAvailable();
QSound::play(QDir::tempPath() + "/bgm.wav");
[/CODE]
The sound file can, however, be played with Phonon!
Re: QSound()::isAvailable false on N900
QSound uses NAS(Network Audio Sound) on Linux/X11. Qt is compiled without the NAS support...
Phonon works because it uses gstreamer.
I think this a well known issue...
If you file the bug, please post here the bug reference number.
Re: QSound()::isAvailable false on N900
Hello,
done as ordered:
QTBUG-11555
Tam
Re: QSound()::isAvailable false on N900
So this means that Simulator won't play any QSound file under Linux ? If so thanks for the bug filling, I am interested in too.
Re: QSound()::isAvailable false on N900
[QUOTE=Guilo19;748788]So this means that Simulator won't play any QSound file under Linux ? If so thanks for the bug filling, I am interested in too.[/QUOTE]
No, it could work there. Anyway if it works on the simulator and it doesn't on the device.. it's useless...isn't it?
Re: QSound()::isAvailable false on N900
[QUOTE=tamhanna;748762]Hello,
done as ordered:
QTBUG-11555
Tam[/QUOTE]
People who are interested on this bug, can check the itsstatus, comments and watch it at [url]http://bugreports.qt.nokia.com/browse/QTBUG-11555[/url]
Re: QSound()::isAvailable false on N900
They have already closed it - not interested in fixing...
Re: QSound()::isAvailable false on N900
[QUOTE=tamhanna;749813]They have already closed it - not interested in fixing...[/QUOTE]
I think so. although NAS build fine in scratchbox.
QSound sucks compared to Phonon or to the new Mobility multimedia framework.
Re: QSound()::isAvailable false on N900
Not really.
Creating looping sound with Phonon is all but impossible.