Increases or decreases the brightness in the image by multiplying the colors in a specific image by a factoring value divided by 100.
public class MultiplyCommand : RasterCommand Public Class MultiplyCommandInherits Leadtools.Imageprocessing.Leadtools.ImageProcessing.RasterCommandImplements Leadtools.Imageprocessing.Leadtools.ImageProcessing.IRasterCommand
public sealed class MultiplyCommand : Leadtools.Imageprocessing.Leadtools.ImageProcessing.IRasterCommand @interface LTMultiplyCommand : LTRasterCommand public class MultiplyCommand extends RasterCommand function Leadtools.ImageProcessing.Color.MultiplyCommand() public ref class MultiplyCommand : public Leadtools.Imageprocessing.Leadtools.ImageProcessing.RasterCommand, Leadtools.Imageprocessing.Leadtools.ImageProcessing.IRasterCommand If the image has a LUT and you want to work on the image data, set RasterImage.UseLookupTable to false. Then, after calling the method, reset the UselookupTable property to true, as follows:
rasterImage.UseLookupTable = false;Method(rasterImage);rasterImage.UseLookupTable = true;
For more information, refer to Changing Brightness and Contrast.
Run the MultiplyCommand on an image with factor = 1.51.
using Leadtools;using Leadtools.Codecs;using Leadtools.ImageProcessing.Color;public void MultiplyCommandExample(){// Load an imageRasterCodecs codecs = new RasterCodecs();codecs.ThrowExceptionsOnInvalidImages = true;RasterImage image = codecs.Load(Path.Combine(LEAD_VARS.ImagesDir, "IMAGE1.CMP"));// Prepare the commandMultiplyCommand command = new MultiplyCommand();command.Factor = 151;// Multiply the colors of the bitmap with 1.51.command.Run(image);codecs.Save(image, Path.Combine(LEAD_VARS.ImagesDir, "Result.jpg"), RasterImageFormat.Jpeg, 24);}static class LEAD_VARS{public const string ImagesDir = @"C:\Users\Public\Documents\LEADTOOLS Images";}
Imports LeadtoolsImports Leadtools.CodecsImports Leadtools.ImageProcessing.ColorPublic Sub MultiplyCommandExample()Dim codecs As New RasterCodecs()codecs.ThrowExceptionsOnInvalidImages = TrueDim leadImage As RasterImage = codecs.Load(Path.Combine(LEAD_VARS.ImagesDir, "IMAGE1.CMP"))' Prepare the commandDim command As MultiplyCommand = New MultiplyCommandcommand.Factor = 151' Multiply the colors of the bitmap with 1.51.command.Run(leadImage)codecs.Save(leadImage, Path.Combine(LEAD_VARS.ImagesDir, "Result.jpg"), RasterImageFormat.Jpeg, 24)End SubPublic NotInheritable Class LEAD_VARSPublic Const ImagesDir As String = "C:\Users\Public\Documents\LEADTOOLS Images"End Class
using Leadtools;using Leadtools.Codecs;using Leadtools.ImageProcessing.Color;using Leadtools.Examples;public void MultiplyCommandExample(RasterImage image, Stream outStream){// Prepare the commandMultiplyCommand command = new MultiplyCommand();command.Factor = 151;// Multiply the colors of the bitmap with 1.51.command.Run(image);// Save result imageRasterCodecs codecs = new RasterCodecs();codecs.Save(image, outStream, RasterImageFormat.Jpeg, 24);image.Dispose();}
Imports LeadtoolsImports Leadtools.CodecsImports Leadtools.ImageProcessing.ColorPublic Sub MultiplyCommandExample(ByVal image As RasterImage, ByVal outStream As Stream)' Prepare the commandDim command As MultiplyCommand = New MultiplyCommand()command.Factor = 151' Multiply the colors of the bitmap with 1.51.command.Run(image)' Save result imageDim codecs As RasterCodecs = New RasterCodecs()codecs.Save(image, outStream, RasterImageFormat.Jpeg, 24)image.Dispose()End Sub
Leadtools.ImageProcessing.Color Namespace
Changing Brightness and Contrast
HistogramContrastCommand Class
HistogramEqualizeCommand Class
Leadtools.ImageProcessing.FillCommand
Leadtools.ImageProcessing.Core.WindowLevelCommand
Leadtools.ImageProcessing.Effects.DeinterlaceCommand
Leadtools.ImageProcessing.Effects.EdgeDetectStatisticalCommand
Leadtools.ImageProcessing.Effects.SmoothEdgesCommand
Leadtools.ImageProcessing.Core.CorrelationListCommand
GrayScaleToDuotoneCommand Class
GrayScaleToMultitoneCommand Class
Leadtools.ImageProcessing.Core.HolePunchRemoveCommand
Leadtools.ImageProcessing.Effects.SkeletonCommand
Leadtools.ImageProcessing.SpecialEffects.BricksTextureCommand
Leadtools.ImageProcessing.SpecialEffects.CanvasCommand
Leadtools.ImageProcessing.Effects.DisplacementCommand
Raster .NET | C API | C++ Class Library | JavaScript HTML5
Document .NET | C API | C++ Class Library | JavaScript HTML5
Medical .NET | C API | C++ Class Library | JavaScript HTML5
Medical Web Viewer .NET
