IMVSCCameraControl

The IMVSCCameraControl Interface from the   MontiVision Smart Control provides methods to setup a video source.

GetProperty Get a property from the video source.
GetPropertyRange Get a property range from the video source.
Load Load a camera setup from the windows registry.
Save Saves the camera setup into the windows registry.
SetProperty Set a property from a video source.

Typelib: MV SmartControl

Video Sourc Property Overview

The following table lists all available camera properties. Not all video sources supports every property.

Property Value
Pan 1
Tilt 2
Roll 3
Zoom 4
Exposure 5
Iris 6
Focus 7
Brightness 8
Contrast 9
Hue 10
Saturation 11
Sharpness 12
Gamma 13
ColorEnable 14
WhiteBalance 15
BacklightCompensation 16
Gain 17

The camera properties have additional flags for manual or automatic setting.

Flag Value
Auto 1
Manual 2

 

Method IMVSCCameraControl::GetProperty

Declaration: Sub GetProperty(CameraFilter As String, Property As Long, Value As Long, Flags As Long)

Get a property from the video source.

Parameter:

CameraFilter Label from the camera source filter within the filter graph configuration.
Property Property number from the property table.
Value Actual property value.
Flags Actual property flag.
Prototype:

HRESULT GetProperty(BSTR CameraFilter, LONG Property, LONG* Value, LONG* Flags);


Method IMVSCCameraControl::GetPropertyRange

Declaration: Sub GetPropertyRange(CameraFilter As String, Property As Long, Min As Long, Max As Long, SteppingDelta As Long, Default As Long, Flags As Long)

Get a property range from the video source.

Parameter:

CameraFilter Label from the camera source filter within the filter graph configuration.
Property Property number from the property table.
Min Min value for the property.
Max Max value for the property.
SteppingDelta Possible value steps for the property.
Default Default value for the property.
Flags Available property flags. If Flags is 0 the property is not supported from the video source.
Prototype:

HRESULT GetPropertyRange(BSTR CameraFilter, LONG Property, LONG* Min, LONG* Max, LONG* SteppingDelta, LONG* Default, LONG* Flags);


Method IMVSCCameraControl::Load

Declaration: Sub Load(CameraFilter As String, Application As String, Key As String, User As Boolean)

Load a camera setup from the windows registry. The camera properties were load from the registry key:

HKEY_xxx\Software\MontiVision\SmartControl\CameraConfig\<Application>\<Key>

Parameter:

CameraFilter Label from the camer source filter within the filter graph configuration.
Application An application label for the registry key.
Key Registry key for the camera data, e.g. display name from the camera.
User If User parameter is TRUE, the camera values are stored under HKEY_CURRENT_USER instead of HKEY_LOCAL_MACHINE.
Prototype:

HRESULT Load(BSTR CameraFilter, BSTR Application, BSTR Key, BOOL User);


Method IMVSCCameraControl::Save

Declaration: Sub Save(CameraFilter As String, Application As String, Key As String, User As Boolean)

Saves the camera setup into the windows registry. The camera properties were saved under the registry key:

HKEY_xxx\Software\MontiVision\SmartControl\CameraConfig\<Application>\<Key>

Parameter:

CameraFilter Label from the camer source filter within the filter graph configuration.
Application An application label for the registry key.
Key Registry key for the camera data, e.g. display name from the camera.
User If User parameter is TRUE, the camera values are stored under HKEY_CURRENT_USER instead of HKEY_LOCAL_MACHINE.
Prototype:

HRESULT Save(BSTR CameraFilter, BSTR Application, BSTR Key, BOOL User);


Method IMVSCCameraControl::SetProperty

Declaration: Sub SetProperty(CameraFilter As String, Property As Long, Value As Long, Flags As Long)

Set a property from a video source.

Parameter:

CameraFilter Label from the camera source filter within the filter graph configuration.
Property Property number from the property table.
Value New property value.
Flags New property flag.
Prototype:

HRESULT SetProperty(BSTR CameraFilter, LONG Property, LONG Value, LONG Flags);