4

I'm making a program in java. I'd like to be able to take pictures from the client's webcam. I've been looking around, i found some APIs, but i can't really make heads of tails of what I downloaded. Anyone know a really simple way to take pictures in java? Thanks a lot!

Oliver Charlesworth
  • 267,707
  • 33
  • 569
  • 680
arrow
  • 174
  • 3
  • 15

2 Answers2

3

Well, I would go with JMF or FMJ, they seem to be the big names in this sort of thing. There is a somewhat-similar question here that contains a few more options, if both of those are a little too "heavy" for you. It might be worth it to give one of them a shot.

EDIT: JMyron might be what you're looking for, according to this answer.

Community
  • 1
  • 1
SuperTron
  • 4,203
  • 6
  • 35
  • 62
0

It's very simple to do it using Marvin:

MarvinVideoInterface videoAdapter = new MarvinJavaCVAdapter();
videoAdapter.connect(0);
MarvinImage image = videoAdapter.getFrame();
MarvinImageIO.saveImage(image, "./res/webcam_picture.jpg");
Gabriel Archanjo
  • 4,547
  • 2
  • 34
  • 41