0

I wrote this Windows app, where I use this code:

VideoCapture cap(videopath.c_str());
if(!cap.isOpened()){    
    cerr << "Unsupported video format!" << endl;
    return -1;
}

I supply an example .avi file with this app, and so far it worked on every single machine(win7, winXP, 32bit, 64bit). But suddenly there is one client who claims he's getting "Unsupported video format!" error with the exactly same .avi file which worked on every other machine so far. He's using win7. What do you think is the problem? Is this some codec issue?

Thank you for any advice. With regards, JP

4

1 回答 1

3

这很可能是安装的编解码器的问题。您必须确保目标机器具有解码您提供的 avi 文件所需的编解码器。

一个简单的解决方案是让您的客户使用提供的编解码器包安装 VLC 播放器。包含在 avi 中的视频很可能包含在包中。另一种解决方案可能是使用 g-spot 并找到视频的确切编码,并将适当的过滤器与您的应用程序捆绑在一起

于 2013-05-23T20:12:44.480 回答