• 10216阅读
  • 0回复

cc1plus.exe:: error: out of memory allocating 1073745919 bytes [复制链接]

上一主题 下一主题
离线sd菜
 
只看楼主 倒序阅读 楼主  发表于: 2010-10-24
— 本帖被 XChinux 执行加亮操作(2010-10-24) —
我想写一个可以播放音频文件的程序,按照网上Building the Phonon backend plugin on Windows using MinGW

的方法先编译phonon,(我的QT是静态的4.7版本的)输入指令:configure -phonon -phonon-backend然后跳出提示,一路默认下去完了后输入指令:mignw32-make,然后编译了大概两个多小时吧,在最后有错误弹出来,好像是undefined的什么的,有两个,我也没细看,就关了,又用了demo里面的qmediaplayer测试了下,能正常运行。
然后在网上找了个最简单的程序:
#include <QApplication>
[pre]#include <QWidget>[/pre][pre]#include <phonon>[/pre][pre]#include <QUrl>
[pre]int main(int argc, char *argv[])[/pre][pre]{[/pre][pre] QApplication app(argc, argv);[/pre]
[pre] QWidget *widget = new QWidget;[/pre][pre] widget->setWindowTitle("Video Player");[/pre][pre] widget->resize(400,400);[/pre]
[pre] Phonon::VideoPlayer *player = new Phonon::VideoPlayer(Phonon::VideoCategory, widget);[/pre][pre] player->load(Phonon::MediaSource(":/file/music/我喜欢.rmvb"));[/pre]
[pre] player->play();[/pre]
[pre] widget->show();[/pre]
[pre] return app.exec();[/pre][pre]}[/pre][pre]出错信息如下:[/pre]

cc1plus.exe:: error: out of memory allocating 1073745919 bytes
我晕了,请问这是怎么回事啊?
快速回复
限100 字节
 
上一个 下一个