Skip to content

Commit

Permalink
Fix build failing because of outdated SNAPSHOT
Browse files Browse the repository at this point in the history
  • Loading branch information
sarxos committed Nov 13, 2012
1 parent e5cddc6 commit a9e1f53
Showing 1 changed file with 13 additions and 7 deletions.
Expand Up @@ -6,10 +6,12 @@
import org.openimaj.image.ImageUtilities;
import org.openimaj.video.capture.Device;
import org.openimaj.video.capture.VideoCapture;
import org.openimaj.video.capture.VideoCaptureException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import com.github.sarxos.webcam.WebcamDevice;
import com.github.sarxos.webcam.WebcamException;


public class OpenImajDevice implements WebcamDevice {
Expand All @@ -21,12 +23,12 @@ public class OpenImajDevice implements WebcamDevice {
* but hope that OpenIMAJ can handle this.
*/
private final static Dimension[] DIMENSIONS = new Dimension[] {
new Dimension(176, 144),
new Dimension(320, 240),
new Dimension(352, 288),
new Dimension(640, 400),
new Dimension(640, 480),
new Dimension(1280, 720),
new Dimension(176, 144),
new Dimension(320, 240),
new Dimension(352, 288),
new Dimension(640, 400),
new Dimension(640, 480),
new Dimension(1280, 720),
};

private Device device = null;
Expand Down Expand Up @@ -79,7 +81,11 @@ public void open() {
return;
}

capture = new VideoCapture(size.width, size.height, device);
try {
capture = new VideoCapture(size.width, size.height, device);
} catch (VideoCaptureException e) {
throw new WebcamException("Cannot initialize video capture", e);
}
open = true;

// what the hell is that something below? that's ugly w/a for black
Expand Down

0 comments on commit a9e1f53

Please sign in to comment.