我想在 j2me 中播放视频,我使用的代码是
int index = 0;
LoadVideo(index);
String url = "file:///e:/videos/Abc.3gp";
try{
Player p = Manager.createPlayer(url);
p.realize();
//Get the video controller
VideoControl video = (VideoControl) p.getControl("VideoControl");
//Get a GUI to display the video
Item videoItem = (Item)video.initDisplayMode(VideoControl.USE_GUI_PRIMITIVE, null);
//videoItem.setPreferredSize(100, 200);
//Append the GUI to a form
form.append(videoItem);
display.setCurrent(form);
//Start the video
p.start();
}catch(IOException ioe){ } catch(MediaException me){ }
问题是仅在小屏幕模式下播放视频,我怎样才能使其适合显示,请有人帮助我....