ShowGammaAdjustmentDlg Example for Visual Basic
Dim RasterColorDlg As New LEADRasterDlgClr
Dim RasterProc As New LEADRasterProcess
Dim nRet As Integer
Private Sub GammaAdjustment_Click()
RasterColorDlg.GammaRedValue = 50
RasterColorDlg.GammaRedValue = 50
RasterColorDlg.GammaGreenValue = 50
RasterColorDlg.GammaBlueValue = 50
RasterColorDlg.EnableGammaAllChannels = True
RasterColorDlg.UIFlags = GAMMAADJUSTMENT_SHOW_PREVIEW Or _
GAMMAADJUSTMENT_SHOW_TOOL_ZOOMLEVEL
RasterColorDlg.Bitmap = LEADRasterView1.Raster.Bitmap
nRet = RasterColorDlg.ShowGammaAdjustmentDlg (hWnd)
If (nRet = 0 And RasterColorDlg.DialogStatus = DLG_OK) Then
RasterProc.GammaCorrect LEADRasterView1.Raster, RasterColorDlg.GammaRedValue
End If
End Sub