Class UtilWebcamCapture

java.lang.Object
boofcv.io.webcamcapture.UtilWebcamCapture

public class UtilWebcamCapture
extends Object
Utility functions related to Webcam capture
  • Constructor Summary

    Constructors
    Constructor Description
    UtilWebcamCapture()  
  • Method Summary

    Modifier and Type Method Description
    static void adjustResolution​(com.github.sarxos.webcam.Webcam webcam, int desiredWidth, int desiredHeight)  
    static @Nullable com.github.sarxos.webcam.Webcam findDevice​(String deviceName)  
    static com.github.sarxos.webcam.Webcam openDefault​(int desiredWidth, int desiredHeight)
    Opens the default camera while adjusting its resolution
    static com.github.sarxos.webcam.Webcam openDevice​(String deviceName, int desiredWidth, int desiredHeight)
    Searches for the first device which matches the pattern.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • UtilWebcamCapture

      public UtilWebcamCapture()
  • Method Details

    • openDefault

      public static com.github.sarxos.webcam.Webcam openDefault​(int desiredWidth, int desiredHeight)
      Opens the default camera while adjusting its resolution
    • openDevice

      public static com.github.sarxos.webcam.Webcam openDevice​(String deviceName, int desiredWidth, int desiredHeight)
      Searches for the first device which matches the pattern. Webcam capture doesn't name devices using the standard "/dev/video0" scheme, but it includes that in its name.
      Parameters:
      deviceName - Partial or complete name of the device you wish to pen
      Returns:
      The webcam it found
    • findDevice

      @Nullable public static @Nullable com.github.sarxos.webcam.Webcam findDevice​(String deviceName)
    • adjustResolution

      public static void adjustResolution​(com.github.sarxos.webcam.Webcam webcam, int desiredWidth, int desiredHeight)