File tree 2 files changed +4
-3
lines changed
webcam-capture/src/main/java/com/github/sarxos/webcam
2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -22,11 +22,13 @@ public class Webcam {
22
22
23
23
private static final Logger LOG = LoggerFactory .getLogger (Webcam .class );
24
24
25
+ //@formatter:off
25
26
private static final String [] DRIVERS_DEFAULT = new String [] {
26
27
"com.github.sarxos.webcam.ds.openimaj.OpenImajDriver" ,
27
28
"com.github.sarxos.webcam.ds.civil.LtiCivilDriver" ,
28
29
"com.github.sarxos.webcam.ds.jmf.JmfDriver" ,
29
30
};
31
+ //@formatter:on
30
32
31
33
private static final List <String > DRIVERS_LIST = new ArrayList <String >(Arrays .asList (DRIVERS_DEFAULT ));
32
34
@@ -221,6 +223,7 @@ public static List<Webcam> getWebcams() {
221
223
driver = WebcamDriverUtils .findDriver (DRIVERS_LIST );
222
224
}
223
225
if (driver == null ) {
226
+ LOG .info ("Webcam driver has not been found, default one will be used!" );
224
227
driver = new DefaultDriver ();
225
228
}
226
229
Original file line number Diff line number Diff line change @@ -53,9 +53,7 @@ protected static WebcamDriver findDriver(List<String> drivers) {
53
53
}
54
54
}
55
55
56
- LOG .error ("Webcam driver has not been found! Please add one to the classpath!" );
57
-
58
- throw new WebcamException ("No webcam driver available" );
56
+ return null ;
59
57
}
60
58
61
59
/**
You can’t perform that action at this time.
0 commit comments