[OpenCV]关于opencv不能打开某些视频得问题

opencv不能打开某些视频困扰了我好久,我一直认为是少安装了某个视频解码器,在尝试了几种解码器后,终于发现安装Xvid解码器后就可以了。它到底是什么东东?它得官方网站http://www.xvid.org/,可以下载最新得解码器。其实就是安装一个mpeg4得解码器而已。一些解码器如下:

orking video codecs

codec name

fourcc

codecfile

out

comments

MPEG-PES output (.mpg or DXR3/DVB card)

-

-

MPES

for hardware decoding

MPEG-1 or 2 (libmpeg2)

-

DVR 
hdv2
mpg1
PIM1
VCR2
mpg2

-

YV12
I420
IYUV
422P

with postprocessing

FFmpeg MPEG-1

-
mpg1
PIM1
VCR2

mpeg1video

YV12
I420
IYUV

-

FFmpeg MPEG-2

-
mpg2
DVR 
hdv2

mpeg2video

YV12
I420
IYUV
422P
444P

-

FFmpeg MPEG-1/2

-

mpg1
mpg2
PIM1
VCR2
DVR 
hdv2

mpegvideo

YV12
I420
IYUV
422P
444P

-

NuppelVideo

NUV1
RJPG

-

I420
IYUV

-

FFmpeg PNG decoder

mpng
MPNG
png

png

BGR32
BGR24
BGR8
Y800
RGB32
RGB24
RGB8

-

PNG image decoder

mpng
MPNG
png

libpng

BGR32
BGR24
BGR8
Y800

Gray scaled PNG with Alpha channel not supported

TGA image decoder

mtga
MTGA

-

BGR32
BGR24

Only 24bpp and 32bpp RGB TGA files supported

SGI image decoder

SGI1

-

BGR24

-

FFmpeg Intel Indeo 3.1/3.2

IV31
iv31
IV32
iv32

indeo3

YVU9

-

Autodesk FLI/FLC Animation

FLIC

flic

BGR8

-

Autodesk RLE decoder

AASC

aasc

BGR24

-

LOCO video decoder

LOCO

loco

422P
YV12
BGR32
BGR24

-

QuickTime Animation (RLE)

rle

qtrle

BGR32
RGB24
BGR15
BGR8

-

QuickTime Apple Video

rpza
azpr

rpza

BGR15

-

Apple Graphics (SMC) codec

smc

smc

BGR8

-

Planar RGB (Photoshop)

8BPS

8bps

BGR32
BGR24
BGR8

-

Creative YUV (libavcodec)

cyuv
CYUV

cyuv

411P

-

Microsoft RLE

-

WRLE

msrle

BGR8

-

Id RoQ File Video Decoder

RoQV

roqvideo

YV12

-

LZO compressed

LZO1

liblzo

YV12
I420
BGR24

-

Theora (free
reworked VP3)

theo
Thra

libtheora

YV12

-

Cinepak Video (native codec)

cvid
CVID

cinepak

YV12
BGR8

-

Cinepak Video

cvid

iccvid.dll

BGR24
BGR15

-

Microsoft Video 1 (native codec)

cram
CRAM
msvc
MSVC
wham
WHAM

msvideo1

BGR15
BGR8

-

AVImszh (native codec)

MSZH

mszh

BGR24

-

AVIzlib (native codec)

ZLIB

zlib

BGR24

-

FFmpeg HuffYUV

HFYU
FFVH

huffyuv

YUY2
422P
YV12
BGR32
BGR24

-

FFV1 (lossless codec)

FFV1

ffv1

411P
444P
422P
YV12
I420
IYUV
YVU9
BGR32

-

FFSNOW (Michael's wavelet codec)

snow
SNOW

snow

YV12

-

FFmpeg ASUS V1

ASV1

asv1

YV12
I420
IYUV

-

FFmpeg ASUS V2

ASV2

asv2

YV12
I420
IYUV

-

FFmpeg ATI VCR1

VCR1

vcr1

YVU9

-

FFmpeg Cirrus Logic AccuPak (CLJR)

CLJR

cljr

411P

-

FFmpeg Sorenson Video v1 (SVQ1)

SVQ1
svq1

svq1

YVU9

-

FFmpeg 4XM video

4XMV

4xm

BGR16

-

Miro VideoXL codec

VIXL

xl

411P

-

QuickDraw native decoder

qdrw

qdraw

RGB24

-

Indeo 2 native decoder

RT21

indeo2

YVU9

-

FFmpeg Flash video

FLV1

flv

YV12

-

FFmpeg DivX ;-) (MS MPEG-4 v3)

MPG3
mpg3
MP43
mp43
DIV5
div5
DIV6
div6
DIV3
div3
DIV4
div4
AP41
COL1
col1
COL0
col0
3IVD
3ivd

msmpeg4

YV12
I420
IYUV

-

FFmpeg M$ MPEG-4 v2

DIV2
div2
MP42
mp42

msmpeg4v2

YV12
I420
IYUV

-

FFmpeg M$ MPEG-4 v1

DIV1
div1
MPG4
mpg4

msmpeg4v1

YV12
I420
IYUV

-

FFmpeg M$ WMV1/WMV7

WMV1
wmv1

wmv1

YV12
I420
IYUV

-

FFmpeg H.264

H264
h264
avc1

h264

YV12
I420
IYUV

-

FFmpeg Sorenson Video v3 (SVQ3)

SVQ3

svq3

YV12
I420
IYUV

-

FFmpeg MPEG-4

FMP4
fmp4
DIVX
divx
DIV1
div1
MP4S
mp4s
M4S2
m4s2
xvid
XVID
XviD
XVIX
DX50
dx50
BLZ0
mp4v
MP4V

UMP4
3IV2
3iv2
DXGM

mpeg4

YV12
I420
IYUV

-

WV1F MPEG-4

WV1F

mpeg4

YV12
I420
IYUV

-

XviD (MPEG-4)

DIVX
divx
xvid
XVID
XviD

libxvidcore.a

YV12
I420
YUY2
UYVY
YVYU
BGR32
BGR24
BGR16
BGR15

-

OpenDivX API (ODIVX
DIVX4
DIVX5
XVID)

mp4v
DIVX
divx
DIV1
div1
MP43
mp43
DIV3
div3
DIV4
div4
AP41
xvid
XVID
XviD
DX50
BLZ0

libdivxdecore.so

YV12
I420
IYUV

with postprocessing

DivX4Linux API (DIVX4
DIVX5
XVID)

mp4v
DIVX
divx
DIV1
div1
MP43
mp43
DIV3
div3
DIV4
div4
AP41
xvid
XVID
XviD
DX50
BLZ0

libdivxdecore.so

YUY2
UYVY
BGR32
BGR24
BGR16
BGR15

with postprocessing

DivX ;-) (MS MPEG-4 v3)

MP43
mp43
DIV5
div5
DIV6
div6
DIV3
div3
DIV4
div4
AP41

divx_c32.ax

YUY2
UYVY
BGR32
BGR24
BGR16
BGR15

with postprocessing

DivX ;-) (MS MPEG-4 v3)

MP43
mp43
DIV5
div5
DIV6
div6
DIV3
div3
DIV4
div4
AP41

divxc32.dll

YUY2
BGR32
BGR24
BGR15

-

Microsoft MPEG-4 v1/v2

DIV2
div2
MP4S
mp4s
MPG4
mpg4
MP42
mp42

mpg4ds32.ax

YUY2

with postprocessing

Microsoft MPEG-4 v1/v2

MPG4
mpg4
MP42
mp42
DIV2

mpg4c32.dll

YUY2
BGR32
BGR24
BGR15

-

Windows Media Video 8

WMV2

wmv8ds32.ax

YV12
I420
IYUV
YUY2
UYVY

-

Windows Media Video 7

WMV1

wmvds32.ax

YUY2
UYVY

-

Windows Media Video 9 DMO

WMV3
WMVP

wmv9dmod.dll

YV12
YUY2
UYVY

-

Windows Media Video DMO

WMV1
WMV2
WMV3
WMVP

wmvdmod.dll

YV12
YUY2
UYVY

-

Windows Media Video Adv DMO

WMVA
WVP2

wmvadvd.dll

YV12
YUY2
UYVY

-

Windows Media Screen Codec 2

MSS1
MSS2

wmsdmod.dll

BGR32
BGR24
BGR16

-

FFmpeg MJPEG decoder

MJPG
mjpg
AVRn
AVDJ
jpeg
mjpa
JFIF
ijpg
IJPG
JPEG
JPGL
LJPG
dmb1

mjpeg

444P
422P
YUY2
YV12
I420
IYUV
BGR32

-

FFmpeg MJPEG-B decoder

mjpb

mjpegb

444P
422P
YUY2
YV12
I420
IYUV

-

Independent JPEG Group's codec

ijpg
IJPG
jpeg
AVRn
AVDJ

libjpeg

RGB24
BGR24
BGR32

-

Morgan Motion JPEG Codec

MJPG
mjpa
mjpb
mjpg
dmb1

m3jpeg32.dll

YUY2
UYVY
BGR32
BGR24
BGR15

-

MainConcept Motion JPEG

MJPG
mjpa
mjpb
mjpg

mcmjpg32.dll

YUY2
UYVY
BGR32
BGR24
BGR15

-

AVID Motion JPEG

AVRn
AVDJ
MJPG
mjpg

AvidAVICodec.dll

BGR24

slooooooooow but stable

LEAD (M)JPEG

MJPG
jpeg
LEAD

LCodcCMP.dll

BGR24
BGR15

supports interlaced MJPEG

Morgan MJPEG2000

MJ2C

m3jp2k32.dll

YV12
I420
IYUV
YUY2
UYVY
BGR32
BGR24
BGR15

-

Vivo H.263

VIVO
vivo
viv1
viv2

ivvideo.dll

BGR32
BGR24
BGR15

-

UB Video H.263/H.263+/H.263++ Decoder

U263
vivo
VIVO
viv1

ubv263d+.ax

BGR24

-

I263

I263
i263
vivo
VIVO
viv1

i263_32.drv

I420
YUY2
BGR32
BGR24
BGR15

-

FFmpeg I263 decoder

I263
i263

h263i

YV12
I420
IYUV

-

FFmpeg H.263+ decoder

H263
U263
h263
X263
viv1
s263

h263

YV12
I420
IYUV

-

CCITT H.261

H261
h261

h261

YV12

-

Intel Indeo 5

IV50
iv50

ir50_32.dll

YV12
IYUV
I420
YUY2
UYVY
BGR32
BGR24
BGR16
BGR15

-

Intel Indeo 5

IV50
iv50

ir50_32.dll

YUY2
BGR32
BGR24
BGR15

-

Intel Indeo 4.1

IV41
iv41

ir41_32.dll

IF09
BGR24
BGR15

-

Intel Indeo 3.1/3.2

IV31
iv31
IV32
iv32

ir32_32.dll

IF09
BGR24
BGR15

-

XAnim's Intel Indeo 5

IV50
iv50

vid_iv50.xa

YVU9

-

XAnim's Intel Indeo 4.1

IV41
iv41

vid_iv41.xa

YVU9

-

XAnim's Intel Indeo 3.1/3.2

IV31
iv31
IV32
iv32

vid_iv32.xa

YVU9

-

Sony Digital Video (DV)

dvsl
dvsd
dvhd
DVSD
dvcp
dvc

qdv.dll

YUY2
UYVY
BGR24
BGR16
BGR15

-

FFmpeg DV decoder

DVSD
dvsd
DVCS
dvcs
dvcp
dvc

dvvideo

411P
YV12

-

Raw DV decoder (libdv)

DVSD
dvsd
DVCS
dvcs
dvcp
dvc 
AVdv

libdv.so.2

YUY2

-

MainConcept DV Codec

DVSD
dvsd
DVCS
dvcs
CDVC
cdvc
dvcp
dvc

mcdvd_32.dll

YUY2
UYVY
BGR32
BGR24
BGR15

-

XAnim's 3ivx Delta 3.5 plugin

3IV1

vid_3ivX.xa

YV12
IYUV
I420

-

Linux RealPlayer 10 RV30/40 decoder

RV30
rv30
RV40
rv40

drvc.so

I420

-

Linux RealPlayer 9 RV40 decoder

RV40
rv40

drv4.so.6.0

I420

-

Win32 RealPlayer 9 RV40 decoder

RV40
rv40

drv43260.dll

I420

-

Mac OS X RealPlayer 9 RV40 decoder

RV40
rv40

drvc.bundle/Contents/MacOS/drvc

I420

-

Linux RealPlayer 8 RV30 decoder

RV30
rv30

drv3.so.6.0

I420

-

Win32 RealPlayer 8 RV30 decoder

RV30
rv30

drv33260.dll

I420

-

Mac OS X RealPlayer 9 RV30 decoder

RV30
rv30

drvc.bundle/Contents/MacOS/drvc

I420

-

Linux RealPlayer 8 RV20 decoder

RV20
rv20

drv2.so.6.0

I420

-

Win32 RealPlayer 8 RV20 decoder

RV20
rv20

drv23260.dll

I420

-

Mac OS X RealPlayer 9 RV20 decoder

RV20
rv20

drv2.bundle/Contents/MacOS/drv2

I420

-

Alparysoft lossless codec dshow

ASLC

aslcodec_dshow.dll

BGR24

-

Alparysoft lossless codec vfw

ASLC

aslcodec_vfw.dll

BGR24

-

Lead CMW wavelet 2.0

LCW2

LCODCCMW2E.dll

BGR24
BGR8

-

FFmpeg RV10 decoder

RV10
rv10
RV13
rv13

rv10

YV12
I420
IYUV

-

On2 Open Source VP3 Codec

VP30
vp30
VP31
vp31

vp31vfw.dll

YUY2
BGR32
BGR24
BGR15

For SSE-systems use fixed DLL from ftp://mplayerhq.hu/MPlayer/samples/drivers32/

On2 VP4 Personal Codec

VP40
VP31
VP30
vp31
vp30

vp4vfw.dll

YUY2
BGR32
BGR24

Decodes also VP3

On2 VP5 Personal Codec

VP50

vp5vfw.dll

YUY2
BGR32
BGR24

-

On2 VP6 Personal Codec

VP60
VP61
VP62

vp6vfw.dll

YUY2
BGR32
BGR24

-

Motion Wavelets

MWV1

icmw_32.dll

BGR24
BGR15

-

ASUS V2

ASV2

asusasv2.dll

UYVY
BGR32
BGR24
BGR15

-

ASUS V1

ASV1

asusasvd.dll

UYVY
BGR32
BGR24
BGR15

-

IBM Ultimotion native decoder

ULTI

ultimotion

YVU9

-

IBM Ultimotion

ULTI

ultimo.dll

YUY2
UYVY
BGR32
BGR24
BGR15

-

Windows Screen Video

MSS1

msscds32.ax

BGR32
BGR24
BGR16
BGR15

-

UCOD-ClearVideo

UCOD

clrviddd.dll

BGR32
BGR24
BGR15

-

ATI VCR-2

VCR2

ativcr2.dll

YV12
BGR24

-

Duck Truemotion1

DUCK

truemotion1

BGR15
BGR16
BGR24

-

TrueMotion 2.0

TM20

tm20dec.ax

BGR32
BGR24
BGR16

YUV faulting

SP5x codec - used by Aiptek MegaCam

SP53
SP54
SP55
SP56
SP57
SP58

sp5x

YV12

-

SP5x codec - used by Aiptek MegaCam

SP53
SP54
SP55
SP56
SP57
SP58

sp5x_32.dll

BGR24
BGR15

-

SoftMedia ViVD V2 codec VfW

GXVE
gxve

ViVD2.dll

YUY2
YV12
I420
YVU9
BGR32
BGR24
BGR15

-

Winnov Videum winx codec

WINX

wnvwinx.dll

BGR32
BGR24
BGR15

-

FFmpeg wnv1 native codec

WNV1

wnv1

422P

-

Winnov Videum wnv1 codec

WNV1

wnvplay1.dll

BGR32
BGR24
BGR15

-

VDOWave codec

VDOM

vdowave.drv

BGR24

-

Vianet Lsvx Video Decoder

lsvx
lsvm
lsvc

lsvxdec.dll

BGR32
BGR24
BGR16

-

VMware video

VMnc

vmnc.dll

BGR24
BGR15
BGR8

-

win32/quicktime 3IV1 (3ivx) decoder

3IV1

3ivx Delta 3.5.qtx

YUY2

-

Win32/QuickTime Avid Meridien Uncompressed

AVUI

AvidQTAVUICodec.qtx

YUY2

-

Win32/QuickTime Cinepak decoder

cvid

QuickTime.qts

YUY2

-

Win32/QuickTime SVQ3 decoder

SVQ3

QuickTimeEssentials.qtx

YUY2

-

VSS Codec Light

VSSV

vsslight.dll

BGR24

-

VSS H.264 New

VSSH

vsshdsd.dll

YV12

-

VSS H.264 Old

VSSH

vssh264.dll

BGR24

-

VSS Wavelet Video Codec

VSSW

vsswlt.dll

BGR24

-

AVIzlib

ZLIB

avizlib.dll

BGR24

24bpp only

AVImszh

MSZH

avimszh.dll

BGR24

24bpp only

Q-Team's QPEG (www.q-team.de)

Q1.0
QPEG
Q1.1
qpeq

qpeg32.dll

BGR8

BGR8 only!

TechSmith Camtasia Screen Codec (native)

TSCC
tscc

camtasia

BGR32
BGR24
BGR15
BGR8

-

TechSmith Camtasia Screen Codec

TSCC
tscc

tsccvid.dll

BGR32
BGR24
BGR15
BGR8

-

FRAPS: Realtime Video Capture

FPS1
fps1

frapsvid.dll

BGR32

Requires a processor with SSE???

RAW RGB32

-
raw 
BGR

-

RGB32

-

RAW RGB24

-
raw 
BGR

-

RGB24

-

RAW RGB16

-
raw 
BGR

-

RGB16

-

RAW BGR32

-

-

BGR32

-

RAW BGR32

-
RGB

-

BGR32

-

RAW BGR24

-

-

BGR24

-

RAW BGR24

-
raw 
RGB

-

BGR24

-

RAW BGR15

-

-

BGR16

-

RAW BGR15

-
raw 
RGB

-

BGR16

-

RAW BGR15

-

-

BGR15

-

RAW BGR15

-
raw 
RGB

-

BGR15

-

RAW BGR8

-

-

BGR8

-

RAW BGR8

-
raw 
RGB

-

BGR8

-

RAW BGR1

-
raw 
RGB

-

BGR1

-

RAW YUY2

-
raw 
yuy2
YUY2

-

YUY2

-

RAW UYVY

-
raw 
uyvy
UYVY

-

UYVY

-

RAW 444P

-
raw 
444p
444P

-

444P

-

RAW 422P

-
raw 
422p
422P

-

422P

-

RAW YV12

-
raw 
yv12
YV12

-

YV12

-

RAW NV21

-
raw 
nv21
NV21

-

YV12

-

RAW NV12

-
raw 
nv12
NV12

-

YV12

-

RAW HM12

-
raw 
hm12
HM12

-

YV12

-

RAW I420

-
raw 
i420
I420
IYUV
iyuv

-

I420
IYUV

-

RAW YVU9

-
raw 
yvu9
YVU9

-

YVU9

-

RAW Y8/Y800

-
Y8 
y800
Y800

-

Y800
Y8

-

New / Untested codecs

codec name

fourcc

codecfile

problem

FFmpeg ZyGo

ZyGo

h263

-

M261

m261
M261

msh261.drv

-

FFmpeg RV20 decoder

RV20
rv20

rv20

-

FFmpeg VP3

VP30
vp30
VP31
vp31
VP3

vp3

-

FFmpeg Theora

theo
Thra

theora

-

CJPG

CJPG

CtWbJpg.DLL

sample files needed (this DLL is decompression only!)

Win32/QuickTime BeHereiVideo decoder

bhiv

BeHereiVideo.qtx

sample file wanted!

Codecs with problems

codec name

fourcc

codecfile

problem

FFmpeg MPEG-1/2 (XvMC)

-

mpg1
mpg2
DVR 
hdv2
PIM1
VCR2

mpegvideo_xvmc

-

Microsoft Video 1

cram
CRAM
msvc
MSVC
wham
WHAM

msvidc32.dll

-vf palette required for 8bpp

HuffYUV

HFYU

huffyuv.dll

-

XAnim's Radius Cinepak Video

cvid

vid_cvid.xa

-

FFmpeg M$ WMV2/WMV8

你可能感兴趣的:(opencv,音视频,ffmpeg)