WebCamera_GrabImage


Captures a frame from a camera using Direct Show interface.

Applications:Not recommended for industrial operation.

Syntax

C++
Python
 
def WebCamera_GrabImage(
	state: WebCamera_GrabImageState,
	outFrame: Image,
	/,
	*,
	inCameraIndex: int | None = None,
	inCameraID: str | None = None,
	inFrameSize: Size | None = None,
	inPixelType: WebCameraInputFormat = WebCameraInputFormat.Any,
	inExposure: int | None = None,
	inExposureAuto: bool = False,
	inFocus: int | None = None,
	inFocusAuto: bool = False,
	inGain: int | None = None,
	inBrightness: int | None = None,
	inContrast: int | None = None,
	inSaturation: int | None = None,
	inWhiteBalance: int | None = None,
	inWhiteBalanceAuto: bool = False
)
-> outResult: bool

Parameters

Name Type Range Default Description
Input will be modified ioState WebCamera_GrabImageState
Input value inCameraIndex int | None 0 - + None Index number of the camera device to connect with
Input value inCameraID str | None None Unique ID of the camera device to connect with
Input value inFrameSize Size | None None Requested size of source frame in pixels selected from camera output formats
Input value inPixelType WebCameraInputFormat WebCameraInputFormat.Any Requested specific pixel type from camera (may change image quality)
Input value inExposure int | None None Manual (fixed) exposure time in log base 2 seconds
Input value inExposureAuto bool False Activates the automatic exposure time control by the camera
Input value inFocus int | None None Manual (fixed) focus point of the camera
Input value inFocusAuto bool False Activates the automatic focus control by the camera
Input value inGain int | None None Camera gain value
Input value inBrightness int | None None Image brightness setting (black level value)
Input value inContrast int | None None Image contrast setting
Input value inSaturation int | None None Image saturation setting
Input value inWhiteBalance int | None None Manual (fixed) white balance setting
Input value inWhiteBalanceAuto bool False Activates the automatic white balance control by the camera
Output value outFrame Image Captured frame