系统配置:jdk1.4和jmf2.0程序片断如下:
try{
mediaURL = new URL("file:/F:/Mtv/Dong_Feng_Po.wmv");
}
catch(MalformedURLException e){
System.out.println(e);
}
if(player!=null) player.close();
try{
player = Manager.createPlayer(mediaURL); if(player!=null){
player.addControllerListener(this);
player.prefetch();
}
else{
System.out.println("无法创建播放器");
}
}
catch(java.io.IOException e1){
System.out.println(e1);
return;
}
catch(javax.media.NoPlayerException e2){
System.out.println("不能找到播放器!");
return;
}出错信息:不能找到播放器!查看jmf.log有如下信息:
#
# JMF Version 2.0
### Platform: Windows 2000, x86, 5.0
## Java VM: Sun Microsystems Inc., 1.4.1$$ Profile: instantiation: 15 ms!! Input DataSource: com.sun.media.protocol.file.DataSource@4204
!! is not compatible with the MediaEngine.
!! It's likely that the DataSource is required to extend PullDataSource;
!! and that its source streams implement the Seekable interface
!! and with random access capability.
请问怎么解决这个问题?谢谢
try{
mediaURL = new URL("file:/F:/Mtv/Dong_Feng_Po.wmv");
}
catch(MalformedURLException e){
System.out.println(e);
}
if(player!=null) player.close();
try{
player = Manager.createPlayer(mediaURL); if(player!=null){
player.addControllerListener(this);
player.prefetch();
}
else{
System.out.println("无法创建播放器");
}
}
catch(java.io.IOException e1){
System.out.println(e1);
return;
}
catch(javax.media.NoPlayerException e2){
System.out.println("不能找到播放器!");
return;
}出错信息:不能找到播放器!查看jmf.log有如下信息:
#
# JMF Version 2.0
### Platform: Windows 2000, x86, 5.0
## Java VM: Sun Microsystems Inc., 1.4.1$$ Profile: instantiation: 15 ms!! Input DataSource: com.sun.media.protocol.file.DataSource@4204
!! is not compatible with the MediaEngine.
!! It's likely that the DataSource is required to extend PullDataSource;
!! and that its source streams implement the Seekable interface
!! and with random access capability.
请问怎么解决这个问题?谢谢
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货