请问JMF可以获取其他电脑摄像头、或者墙上那种监控的摄像头不
。用java+swing做一个视频监控的程序需要用到
JMF根据ip指定摄像头
答案:2 悬赏:10 手机版
解决时间 2021-04-10 02:15
- 提问者网友:动次大次蹦擦擦
- 2021-04-09 16:42
最佳答案
- 五星知识达人网友:一袍清酒付
- 2021-04-09 17:25
String str2 = "vfw:Microsoft WDM Image Capture (Win32):0";
di = CaptureDeviceManager.getDevice(str2);
ml = di.getLocator();
try {
player = Manager.createRealizedPlayer(ml);
player.start();
Component comp = player.getVisualComponent();
if (comp != null) {
add(comp, BorderLayout.NORTH);
}
Panel panel1 = new Panel(new BorderLayout());
panel1.add(capture, BorderLayout.NORTH);
panel1.add(new Label("请输入对应的文件名:"), BorderLayout.WEST);
panel1.add(num, BorderLayout.CENTER);
panel1.add(save, BorderLayout.SOUTH);
add(panel1, BorderLayout.CENTER);
add(imgpanel, BorderLayout.SOUTH);
} catch (Exception e) {
e.printStackTrace();
}
di = CaptureDeviceManager.getDevice(str2);
ml = di.getLocator();
try {
player = Manager.createRealizedPlayer(ml);
player.start();
Component comp = player.getVisualComponent();
if (comp != null) {
add(comp, BorderLayout.NORTH);
}
Panel panel1 = new Panel(new BorderLayout());
panel1.add(capture, BorderLayout.NORTH);
panel1.add(new Label("请输入对应的文件名:"), BorderLayout.WEST);
panel1.add(num, BorderLayout.CENTER);
panel1.add(save, BorderLayout.SOUTH);
add(panel1, BorderLayout.CENTER);
add(imgpanel, BorderLayout.SOUTH);
} catch (Exception e) {
e.printStackTrace();
}
全部回答
- 1楼网友:低音帝王
- 2021-04-09 18:30
我。。知。。道
加。。我。。私。。聊
我要举报
如以上问答信息为低俗、色情、不良、暴力、侵权、涉及违法等信息,可以点下面链接进行举报!
大家都在看
推荐资讯