Brightness
Top  Previous  Next

Description

Returns or sets the row value of the brightness


Syntax


[VB]
objActiveDcam.Brightness [= Value]


[C/C++]
HRESULT get_Brightness( long *pBrightness );
HRESULT put_Brightness( long Brightness );



Data Type
[VB]

Long

Parameters
[C/C++]

pBrightness [out,retval]  
Pointer to the current brightness value  
Brightness [in]  
The brightness value to be set  


Return Values


S_OK  
Success  
E_FAIL  
The brightness control is not available for the selected camera  
E_INVALIDARG  
The value is out of range  
 

Example


The following VB example demonstrates the use of a scroll control for real-time adjustment of the camera's brightness.

Private Sub
 Form_Load()

ActiveDcam1.Acquire=
True

HScroll1.Value = ActiveDcam1.Brightness
HScroll1.Min = ActiveDcam1.GetBrightnessMin
HScroll1.Max = ActiveDcam1.GetBrightnessMax
End Sub


Private Sub
 HScroll1_Scroll()

ActiveDcam1.Brightness = HScroll1.Value

End Sub

 

Remarks


This property changes the black level of the video by adding a constant amount of luminance to each pixel. The valid property range is reported by the GetBrightnessMin and GetBrightnessMax methods. Note that the property is available only if the currently selected camera supports software brightness control.