Client Image Processing Commands

The LEADTOOLS WebImageViewer supports a group of image processing commands that can be applied to the loaded image through the Leadtools.Web.Controls.WebImageViewer.ApplyCommand(leadtools.imageprocessing.rastercommand) method.

The following table contains the server/client commands that are currently supported by the WebImageViewer control, and how to get or set the client command class properties on the client side.

Server Command Client Command Access Command Properties Through:
AutoCropCommand AutoCropCommand(threshold)

getThreshold(): integer

setThreshold(threshold: integer)

BalanceColorCommandFactor BalanceColorCommandFactor(toRed, toGreen and toBlue)

getToRed(): double

setToRed(toRed: double)

getToGreen(): double

setToGreen(toGreen: double)

getToBlue(): double

setToBlue(toBlue:double)

BalanceColorsCommand BalanceColorsCommand(redFactor, greenFactor and blueFactor)

getRedFactor():BalanceColorsCommand

setRedFactor(redFactor: BalanceColorCommandFactor)

getGreenFactor():BalanceCommand

setGreenFactor(greenFactor: BalanceColorCommandFactor)

getBlueFactor():BalanceCommand

setBlueFactor(blueFactor: BalanceColorCommandFactor)

BorderRemoveCommand BorderRemoveCommand(flags, border, percent, whiteNoiseLength, variance)

getFlags():BorderRemoveCommandFlags

setFlags(flags: BorderRemoveCommandFlags)

getBorder():BorderRemoveCommandFlags

setBorder(border: BorderRemoveBorderFlags)

getPercent():integer

setPercent(percent: integer)

getWhiteNoiseLength():integer

setWhiteNoiseLength(whiteNoiseLength: integer)

getVariance():

setVariance(variance: integer)

ChangeContrastCommand ChangeContrastCommand(contrast)

getContrast(): integer

setContrast(contrast: integer)

ChangeHueCommand ChangeHueCommand(angle)

getAngle(): integer

setAngle(angle: integer)

ChangeIntensityCommand ChangeIntensityCommand(brightness)

getBrightness(): integer

setBrightness(brightness: integer)

ChangeSaturationCommand ChangeSaturationCommand(change)

getChange(): integer

setChange(change: integer)

ColorHalftoneCommand ColorHalftoneCommand(maximumRadius, cyanAngle, magentaAngle, yellowAngle, blackAngle)

getMaximumRadius():integer

setMaximumRadius(maximumRadius:integer)

getCyanAngle():integer

setCyanAngle(cyanAngle:integer)

getMagentaAngle():integer

setMagentaAngle(magentaAngle:integer)

getYellowAngle():integer

setYellowAngle(yellowAngle:integer)

getBlackAngle():integer

setBlackAngle(blackAngle:integer)

ConvertSignedToUnsignedCommand ConvertSignedToUnsignedCommand(type)

getType():ConvertSignedToUnsignedCommandType

setType(type: ConvertSignedToUnsignedCommandType)

ConvertUnsignedToSignedCommand ConvertUnsignedToSignedCommand(type)

getType():ConvertSignedToUnsignedCommandType

setType(type:ConvertUnsignedToSignedCommandType)

DeskewCommand DeskewCommand(fillColor, flags)

getFillColor(): string (CSS color)

setFillColor(fillColor: string (CSS color) )

getFlags(): DeskewCommandFlags)

setFlags(flags:

DespeckleCommand DespeckleCommand() -
DotRemoveCommand DotRemoveCommand(flags, minimumDotWidth, minimumDotHeight, maximumDotWidth, maximumDotHeight)

getFlags():DotRemoveCommandFlags

setFlags(flags: DotRemoveCommandFlags)

getMinimumDotWidth(): integer

setMinimumDotWidth(minimumDotWidth: integer)

getMinimumDotHeight(): integer

setMinimumDotHeight(minimumDotHeight: integer)

getMaximumDotWidth(): integer

setMaximumDotWidth(maximumDotWidth: integer)

getMaximumDotHeight():integer

setMaximumDotHeight(maximumDotHeight: integer)

EmbossCommand EmbossCommand(direction, depth)

getDirection():EmbossCommandDirection

setDirection(direction: EmbossCommandDirection)

getDepth():integer

setDepth(depth:integer)

FlipCommand FlipCommand(horizontal)

getHorizontal(): boolean

setHorizontal(horizontal: boolean)

FreeHandWaveCommand FreeHandWaveCommand(amplitudes, scale, waveLength, angle, fillColor, flags)

getAmplitudes(): Array of integer

setAmplitudes(amplitudes: Array of integer)

getScale(): integer

setScale(scale: integer)

getWaveLength(): integer

setWaveLength(waveLength: integer)

getAngle(): integer

setAngle(angle: integer)

getFillColor(): string (CSS Color)

setFillColor(fillColor: string (CSS Color))

getFlags(): FreeHandWaveCommandFlags

setFlags(flags: FreeHandWaveCommandFlags)

GammaCorrectCommand GammaCorrectCommand(gamma)

getGamma():integer

setGamma(gamma: integer)

GaussianCommand GaussianCommand(radius)

getRadius():integer

setRadius(radius:integer)

GrayscaleCommand GrayscaleCommand() -
GrayScaleExtendedCommand GrayScaleExtendedCommand(redFactor, greenFactorblueFactor)

getRedFactor():integer

setRedFactor(redFactor: integer)

getGreenFactor():integer

setGreenFactor(greenFactor: integer)

getBlueFactor():integer

setBlueFactor(blueFactor: integer)

HalfToneCommand HalfToneCommand(type, angle, dimension)

getType():HalfToneCommandType

setType(type :HalfToneCommandType)

getAngle():integer

setAngle(angle : integer)

getDimension():integer

setDimension(dimension :integer)

HalfTonePatternCommand HalfTonePatternCommand(contrast, ripple, angleContrast, angleRipple, angleOffset, foreGroundColor, backGroundColor, type)

getContrast(): integer

setContrast(contrast: integer)

getRipple(): integer

setRipple(ripple: integer)

getAngleContrast(): integer

setAngleContrast(angleContrast: integer)

getAngleRipple(): integer

setAngleRipple(angleRipple: integer)

getAngleOffset(): integer

setAngleOffset(angleOffset: integer)

getForeGroundColor(): string (CSS color)

setForeGroundColor(foreColor: string (CSS color))

getBackGroundColor(): string (CSS color)

setBackGroundColor(backColor: string (CSS color))

getType(): HalfTonePatternCommandType

setType(type: HalfTonePatternCommandType)

HistogramContrastCommand HistogramContrastCommand(contrast)

getContrast():integer

setContrast(contrast :integer)

HistogramEqualizeCommand HistogramEqualizeCommand(type)

getType():HistogramEqualizeType

setType(type : HistogramEqualizeType)

HolePunchRemoveCommand HolePunchRemoveCommand(flags, location, minimumHoleCount, maximumHoleCount, minimumHoleWidth, minimumHoleHeight, maximumHoleWidth, maximumHoleHeight)

getFlags(): HolePunchRemoveCommandFlags

setFlags(flags: HolePunchRemoveCommandFlags)

getLocation(): HolePunchRemoveCommandLocation

setLocation(location: HolePunchRemoveCommandLocation)

getMinimumHoleCount(): integer

setMinimumHoleCount(minimumHoleCount: integer)

getMaximumHoleCount(): integer

setMaximumHoleCount(maximumHoleCount: integer)

getMinimumHoleWidth(): integer

setMinimumHoleWidth(minimumHoleWidth: integer)

getMinimumHoleHeight(): integer

setMinimumHoleHeight(minimumHoleHeight: integer)

getMaximumHoleWidth(): integer

setMaximumHoleWidth(maximumHoleWidth: integer)

getMaximumHoleHeight(): integer

setMaximumHoleHeight(maximumHoleHeight: integer)

IntensityDetectCommand IntensityDetectCommand(lowThreshold, highThreshold, inColor, outColor and channel)

getLowThreshold():

setLowThreshold(lowThreshold: integer)

getHighThreshold(): integer

setHighThreshold(highThreshold: integer)

getInColor(): string (CSS Color)

setInColor(inColor: string (CSS Color))

getOutColor(): string (CSS Color)

setOutColor(outColor: string (CSS Color))

getChannel(): IntensityDetectCommandFlags

setChannel(channel: IntensityDetectCommandFlags)

InvertCommand InvertCommand() -
InvertedTextCommand"/> InvertedTextCommand(flags, minimumInvertWidth, minimumInvertHeight, minimumBlackPercent, maximumBlackPercent)

getFlags(): InvertedTextCommandFlags

setFlags(flags: InvertedTextCommandFlags)

getMinimumInvertWidth(): integer

setMinimumInvertWidth(minimumInvertWidth: integer)

getMinimumInvertHeight(): integer

setMinimumInvertHeight(minimumInvertHeight: integer)

getMinimumBlackPercent(): integer

setMinimumBlackPercent(minimumBlackPercent: integer)

getMaximumBlackPercent(): integer

setMaximumBlackPercent(maximumBlackPercent: integer)

LineRemoveCommand LineRemoveCommand(flags, minimumLineLength, maximumLineWidth, wall, maximumWallPercent, gapLength, variance, type)

getFlags(): LineRemoveCommandFlags

setFlags(flags: LineRemoveCommandFlags)

getMinimumLineLength(): integer

setMinimumLineLength(minimumLineLength: integer)

getMaximumLineWidth(): integer

setMaximumLineWidth(maximumLineWidth: integer)

getWall(): integer

setWall(wall: integer)

getMaximumWallPercent(): integer

setMaximumWallPercent(maximumWallPercent: integer)

getGapLength(): integer

setGapLength(gapLength: integer)

getVariance(): integer

setVariance(variance: integer)

getType(): LineRemoveCommandType

setType(type: LineRemoveCommandType)

MaximumCommand MaximumCommand(dimension)

getDimension():integer

setDimension(dimension: integer)

MedianCommand MedianCommand(dimension)

getDimension():integer

setDimension(dimension: integer)

MinimumCommand MinimumCommand(dimension)

getDimension():integer

setDimension(dimension: integer)

OffsetCommand OffsetCommand(horizontalShift, verticalShift, backColor, type)

getHorizontalShift(): integer

setHorizontalShift(horizontalShift: integer)

getVerticalShift(): integer

setVerticalShift(verticalShift: integer)

getBackColor(): string (CSS color)

setBackColor(backColor: string (CSS color))

getType(): OffsetCommandType

setType(type: OffsetCommandType)

RemapHueCommand RemapHueCommand(mask, hueTable, saturationTable, valueTable and lookUpTableLength)

getMask(): Array of integer

setMask(mask: Array of integer)

getHueTable(): Array of integer

setHueTable(hueTable: Array of integer)

getSaturationTable(): Array of integer

setSaturationTable(saturationTable: Array of integer)

getValueTable(): Array of integer

setValueTable(valueTable: Array of integer)

getLookUpTableLength(): integer

setLookUpTableLength(lookUpTableLength: integer)

RemapIntensityCommand RemapIntensityCommand(flags, lookupTable)

getFlags(): RemapIntensityCommandFlags

setFlags(flags: RemapIntensityCommandFlags)

getLookupTable(): Array of integer

setLookupTable(lookupTable: Array of integer)

RemoveRedEyeCommand RemoveRedEyeCommand(newColor, threshold and lightness)

getNewColor(): string (CSS Color)

setNewColor(newColor: string (CSS Color))

getThreshold(): integer

setThreshold(threshold: integer)

getLightness(): integer

setLightness(lightness: integer)

SharpenCommand SharpenCommand(sharpness)

getSharpness():integer

setSharpness(sharpness :integer)

SmoothCommand SmoothCommand(flags, length)

getFlags(): SmoothCommandFlags

setFlags(flags: SmoothCommandFlags)

getLength(): integer

setLength(length: integer)

SpatialFilterCommand SpatialFilterCommand(predefinedFilter)

getPredefinedFilter(): SpatialFilterCommandPredefined

setPredefinedFilter(predefinedFilter: SpatialFilterCommandPredefined)

StretchIntensityCommand StretchIntensityCommand() -
UnsharpMaskCommand UnsharpMaskCommand(amount, radius, threshold, colorType)

getAmount(): integer

setAmount(amount: integer)

getRadius(): integer

setRadius(radius: integer)

getThreshold(): integer

setThreshold(threshold: integer)

getColorType(): UnsharpMaskCommandColorType

setColorType(colorType: UnsharpMaskCommandColorType)

RotateCommand RotateCommand(angle, flags, fillColor)

getAngle(): integer

setAngle(angle: integer)

getFlags(): RotateCommandFlags

setFlags(Flags: RotateCommandFlags)

getFillColor(): string (CSS Color)

setFillColor(fillColor: string (CSS Color))

To apply one of the above commands to the image from client-side do something like the following:

// this code rotates the image of WebImageViewer1 by 45 degrees. 
function RotateImage() 
{ 
    var cmd = new RotateCommand(4500, RotateCommandFlags.Bicubic, '#FF00FF'); 
    WebImageViewer1.WebImageViewer.ApplyCommand(cmd); 
} 

WebImageViewer Client Class WebImageViewer ApplyCommand Method

Help Version 19.0.2017.10.27
Products | Support | Contact Us | Copyright Notices
© 1991-2017 LEAD Technologies, Inc. All Rights Reserved.
LEADTOOLS Imaging, Medical, and Document