问题描述
我想从Opencv写入.flv
文件,并花了很多时间...
OpenCv 2.3文档说我们可以使用此编解码器创建flv文件
I want to write .flv
file from Opencv and spent so much time on it...
OpenCv 2.3 Documentation says we can create flv file with this codec
CV_FOURCC('F','L','V','1')
但是我总是遇到这个错误.
but I am always getting this error.
[flv @ 0x9bf5000] Tag FLV1/0x31564c46 incompatible with output codec id '22'
请帮助....目前,我在 Ubuntu 10.10
Please help....Currently I am using OpenCv 2.3 on Ubuntu 10.10
推荐答案
我知道这已经很老了,但是我会把自己的经验加到这堵墙上,以防将来有人遇到这个问题.
I know this is quite old, but I'll add my experience to this wall incase future people have this problem.
我在使用PIM1 fourCC进行输出时遇到了此问题-从
I encountered this using the PIM1 fourCC for output - my problem was solved when I changed from
video_output = cvCreateVideoWriter("disparity_output.mov", CV_FOURCC('P', 'I', 'M', '1'), 32, size, 0);
收件人:
video_output = cvCreateVideoWriter("disparity_output.mkv", CV_FOURCC('P', 'I', 'M', '1'), 32, size, 0);
将输出路径更改为具有可接受的文件扩展名(或者我假设是).不确定是否有帮助,但是对我有用.
changing the output path to have a file extension that was acceptable (or so I assume). Not sure if it helps, but it worked for me.
这篇关于Opencv CV_FOURCC('F','L','V','1')不起作用吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!