JMF在抓取到视频摄像头后提示一下错误:
Unable to handle format: YUV Video Format: Size = java.awt.Dimension[width=640,height=480] MaxDataLength = 614400 DataType = class [B yuvType = 32 StrideY = 1280 StrideUV = 1280 OffsetY = 0 OffsetU = 1 OffsetV = 3
Failed to realize: com.sun.media.PlaybackEngine@8c436b
Error: Unable to realize com.sun.media.PlaybackEngine@8c436b
javax.media.CannotRealizeException
at javax.media.Manager.blockingCall(Manager.java:2005)
at javax.media.Manager.createRealizedPlayer(Manager.java:554)
at com.creatplay.FirstCapture.<init>(FirstCapture.java:70)
at com.creatplay.FirstCapture.main(FirstCapture.java:103)
我知道是格式的问题从而不能创建播放器,但是不知道该如何解决,希望能有人帮我解答
附部分代码:
- Java code
captureDeviceInfo=CaptureDeviceManager.getDevice("vfw:Microsoft WDM Image Capture (Win32):0"); mediaLocator=new MediaLocator("vfw://0"); imagePanel=new ImagePanel(); capture=new JButton("拍照"); capture.addActionListener(this); DataSource ds = new DataSource(); ds.setLocator(mediaLocator);
------解决方案--------------------------------------------------------
mark一下。。。晚上再说。。。
------解决方案--------------------------------------------------------
不会,帮你顶下
------解决方案--------------------------------------------------------
支持,会的快进
------解决方案--------------------------------------------------------
帮顶
------解决方案--------------------------------------------------------
顶!!!
顶!!!
顶!!!
顶!!!
顶!!!
------解决方案--------------------------------------------------------
------解决方案--------------------------------------------------------
顶一下。。。