ON THIS PAGE

  • CameraControl
  • Examples of functionality
  • Reference

CameraControl

This message is used for controlling the ColorCamera as well as the MonoCamera. The message handles things like capturing still images, configuring auto focus, anti banding, white balance, scenes, effects etc.

Examples of functionality

Reference

class

depthai.CameraControl(depthai.Buffer)

class
AntiBandingMode
Members:    OFF    MAINS_50_HZ    MAINS_60_HZ    AUTO
class
AutoFocusMode
Members:    OFF    AUTO    MACRO    CONTINUOUS_VIDEO    CONTINUOUS_PICTURE    EDOF
class
AutoWhiteBalanceMode
Members:    OFF    AUTO    INCANDESCENT    FLUORESCENT    WARM_FLUORESCENT    DAYLIGHT    CLOUDY_DAYLIGHT    TWILIGHT    SHADE
class
CaptureIntent
Members:    CUSTOM    PREVIEW    STILL_CAPTURE    VIDEO_RECORD    VIDEO_SNAPSHOT    ZERO_SHUTTER_LAG
class
Command
Members:    START_STREAM    STOP_STREAM    STILL_CAPTURE    MOVE_LENS    AF_TRIGGER    AE_MANUAL    AE_AUTO    AWB_MODE    SCENE_MODE    ANTIBANDING_MODE    EXPOSURE_COMPENSATION    AE_LOCK    AE_TARGET_FPS_RANGE    AWB_LOCK    CAPTURE_INTENT    CONTROL_MODE    FRAME_DURATION    SENSITIVITY    EFFECT_MODE    AF_MODE    NOISE_REDUCTION_STRENGTH    SATURATION    BRIGHTNESS    STREAM_FORMAT    RESOLUTION    SHARPNESS    CUSTOM_USECASE    CUSTOM_CAPT_MODE    CUSTOM_EXP_BRACKETS    CUSTOM_CAPTURE    CONTRAST    AE_REGION    AF_REGION    LUMA_DENOISE    CHROMA_DENOISE    WB_COLOR_TEMP
class
ControlMode
Members:    OFF    AUTO    USE_SCENE_MODE
class
EffectMode
Members:    OFF    MONO    NEGATIVE    SOLARIZE    SEPIA    POSTERIZE    WHITEBOARD    BLACKBOARD    AQUA
class
FrameSyncMode
Members:    OFF    OUTPUT    INPUT
class
SceneMode
Members:    UNSUPPORTED    FACE_PRIORITY    ACTION    PORTRAIT    LANDSCAPE    NIGHT    NIGHT_PORTRAIT    THEATRE    BEACH    SNOW    SUNSET    STEADYPHOTO    FIREWORKS    SPORTS    PARTY    CANDLELIGHT    BARCODE
method
__init__(self)
Construct CameraControl message
method
get(self) -> RawCameraControl: RawCameraControl
Retrieve configuration data for CameraControl.  Returns:     config for CameraControl
method
getCaptureStill(self) -> bool: bool
Check whether command to capture a still is set  Returns:     True if capture still command is set
method
method
getLensPosition(self) -> int: int
Retrieves lens position, range 0..255. Returns -1 if not available
method
getLensPositionRaw(self) -> float: float
Retrieves lens position, range 0.0f..1.0f.
method
getSensitivity(self) -> int: int
Retrieves sensitivity, as an ISO value
method
set(self, config: RawCameraControl) -> CameraControl: CameraControl
Set explicit configuration.  Parameter ``config``:     Explicit configuration
method
setAntiBandingMode(self, mode: RawCameraControl.AntiBandingMode) -> CameraControl: CameraControl
Set a command to specify anti-banding mode. Anti-banding / anti-flicker works in auto-exposure mode, by controlling the exposure time to be applied in multiples of half the mains period, for example in multiple of 10ms for 50Hz (period 20ms) AC-powered illumination sources.  If the scene would be too bright for the smallest exposure step (10ms in the example, with ISO at a minimum of 100), anti-banding is not effective.  Parameter ``mode``:     Anti-banding mode to use. Default: `MAINS_50_HZ`
method
setAutoExposureCompensation(self, compensation: int) -> CameraControl: CameraControl
Set a command to specify auto exposure compensation  Parameter ``compensation``:     Compensation value between -9..9, default 0
method
method
method
setAutoExposureLock(self, lock: bool) -> CameraControl: CameraControl
Set a command to specify lock auto exposure  Parameter ``lock``:     Auto exposure lock mode enabled or disabled
method
setAutoExposureRegion(self, startX: int, startY: int, width: int, height: int) -> CameraControl: CameraControl
Set a command to specify auto exposure region in pixels. Note: the region should be mapped to the configured sensor resolution, before ISP scaling  Parameter ``startX``:     X coordinate of top left corner of region  Parameter ``startY``:     Y coordinate of top left corner of region  Parameter ``width``:     Region width  Parameter ``height``:     Region height
method
setAutoFocusLensRange(self, infinityPosition: int, macroPosition: int) -> CameraControl: CameraControl
Set autofocus lens range, `infinityPosition < macroPosition`, valid values `0..255`. May help to improve autofocus in case the lens adjustment is not typical/tuned
method
setAutoFocusMode(self, mode: RawCameraControl.AutoFocusMode) -> CameraControl: CameraControl
Set a command to specify autofocus mode. Default `CONTINUOUS_VIDEO`
method
setAutoFocusRegion(self, startX: int, startY: int, width: int, height: int) -> CameraControl: CameraControl
Set a command to specify focus region in pixels. Note: the region should be mapped to the configured sensor resolution, before ISP scaling  Parameter ``startX``:     X coordinate of top left corner of region  Parameter ``startY``:     Y coordinate of top left corner of region  Parameter ``width``:     Region width  Parameter ``height``:     Region height
method
method
setAutoWhiteBalanceLock(self, lock: bool) -> CameraControl: CameraControl
Set a command to specify auto white balance lock  Parameter ``lock``:     Auto white balance lock mode enabled or disabled
method
setAutoWhiteBalanceMode(self, mode: RawCameraControl.AutoWhiteBalanceMode) -> CameraControl: CameraControl
Set a command to specify auto white balance mode  Parameter ``mode``:     Auto white balance mode to use. Default `AUTO`
method
setBrightness(self, value: int) -> CameraControl: CameraControl
Set a command to adjust image brightness  Parameter ``value``:     Brightness, range -10..10, default 0
method
setCaptureIntent(self, mode: RawCameraControl.CaptureIntent) -> CameraControl: CameraControl
Set a command to specify capture intent mode  Parameter ``mode``:     Capture intent mode
method
method
setChromaDenoise(self, value: int) -> CameraControl: CameraControl
Set a command to adjust chroma denoise amount  Parameter ``value``:     Chroma denoise amount, range 0..4, default 1
method
setContrast(self, value: int) -> CameraControl: CameraControl
Set a command to adjust image contrast  Parameter ``value``:     Contrast, range -10..10, default 0
method
setControlMode(self, mode: RawCameraControl.ControlMode) -> CameraControl: CameraControl
Set a command to specify control mode  Parameter ``mode``:     Control mode
method
setEffectMode(self, mode: RawCameraControl.EffectMode) -> CameraControl: CameraControl
Set a command to specify effect mode  Parameter ``mode``:     Effect mode
method
setExternalTrigger(self, numFramesBurst: int, numFramesDiscard: int) -> CameraControl: CameraControl
Set a command to enable external trigger snapshot mode  A rising edge on the sensor FSIN pin will make it capture a sequence of `numFramesBurst` frames. First `numFramesDiscard` will be skipped as configured (can be set to 0 as well), as they may have degraded quality
method
setFrameSyncMode(self, mode: RawCameraControl.FrameSyncMode) -> CameraControl: CameraControl
Set the frame sync mode for continuous streaming operation mode, translating to how the camera pin FSIN/FSYNC is used: input/output/disabled
method
setLumaDenoise(self, value: int) -> CameraControl: CameraControl
Set a command to adjust luma denoise amount  Parameter ``value``:     Luma denoise amount, range 0..4, default 1
method
method
setManualFocus(self, lensPosition: int) -> CameraControl: CameraControl
Set a command to specify manual focus position  Parameter ``lensPosition``:     specify lens position 0..255
method
setManualFocusRaw(self, lensPositionRaw: float) -> CameraControl: CameraControl
Set a command to specify manual focus position (more precise control).  Parameter ``lensPositionRaw``:     specify lens position 0.0f .. 1.0f  Returns:     CameraControl&
method
setManualWhiteBalance(self, colorTemperatureK: int) -> CameraControl: CameraControl
Set a command to manually specify white-balance color correction  Parameter ``colorTemperatureK``:     Light source color temperature in kelvins, range 1000..12000
method
setSaturation(self, value: int) -> CameraControl: CameraControl
Set a command to adjust image saturation  Parameter ``value``:     Saturation, range -10..10, default 0
method
setSceneMode(self, mode: RawCameraControl.SceneMode) -> CameraControl: CameraControl
Set a command to specify scene mode  Parameter ``mode``:     Scene mode
method
setSharpness(self, value: int) -> CameraControl: CameraControl
Set a command to adjust image sharpness  Parameter ``value``:     Sharpness, range 0..4, default 1
method
method
method
method
setStrobeExternal(self, gpioNumber: int, activeLevel: int) -> CameraControl: CameraControl
Enable STROBE output driven by a MyriadX GPIO, optionally configuring the polarity This normally requires a FSIN/FSYNC/trigger input for MyriadX (usually GPIO 41), to generate timings
method
setStrobeSensor(self, activeLevel: int) -> CameraControl: CameraControl
Enable STROBE output on sensor pin, optionally configuring the polarity. Note: for many sensors the polarity is high-active and not configurable
class

depthai.CameraControl.Command

variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
method
method
method
method
method
method
method
method
method
method
property
property
class

depthai.CameraControl.SceneMode

variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
variable
method
method
method
method
method
method
method
method
method
method
property
property

Need assistance?

Head over to Discussion Forum for technical support or any other questions you might have.