Leadtools.Windows.Media.Effects Send comments on this topic. | Back to Introduction - All Topics | Help Version 15.8.31
SampleTargetCommandBitmapEffect Class
See Also  Members  
Leadtools.Windows.Media.Effects.Color Namespace : SampleTargetCommandBitmapEffect Class




Corrects color values by shifting the sample colors to the target colors. This command is available in the Raster Pro and above toolkits.

Syntax

Visual Basic (Declaration) 
Public Class SampleTargetCommandBitmapEffect 
   Inherits RasterCommandBitmapEffect
Visual Basic (Usage)Copy Code
Dim instance As SampleTargetCommandBitmapEffect
C# 
public class SampleTargetCommandBitmapEffect : RasterCommandBitmapEffect 
Managed Extensions for C++ 
public __gc class SampleTargetCommandBitmapEffect : public RasterCommandBitmapEffect 
C++/CLI 
public ref class SampleTargetCommandBitmapEffect : public RasterCommandBitmapEffect 

Example

Run the SampleTargetCommandBitmapEffect on an image.

Remarks

  • For example, suppose you are working with a color image. In the SampleColor property or the sampleColor parameter, set the red value portion of the Color structure to 125, the green portion to 165 and the blue portion to 100. In the TargetColor property or the targetColor parameter you set the red value portion to 170, the green to 120 and the blue to 200. If you set SampleTargetCommandBitmapEffectsFlags.Blue in the Flags property or the flags parameter, then for every pixel in the image that has a blue value of 100, that blue value will be changed to 200, thus shifting the colors in the image. Depending on whether you set SampleTargetCommandBitmapEffectsFlags.Low, SampleTargetCommandBitmapEffectsFlags.Mid, or SampleTargetCommandBitmapEffectsFlags.High, either the shadow values in the blue channel will be remapped, or the midtone values in the blue channel will be remapped, or the highlight values in the blue channel will be remapped.
  • This command supports 12 and 16-bit grayscale and 48 and 64-bit color images.
  • For gray scale images the gray value of the SampleColor and TargetColor properties or the sampleColor and targetColor parameters are used, and the different channel flags have the same effect since it works on the same channel (gray channel). Support for 12 and 16-bit grayscale and 48 and 64-bit color images is available only in the Document/Medical toolkits.
  • This command does not support signed data images.
  • This command does not support 32-bit grayscale images.

Inheritance Hierarchy

System.Object
   System.Windows.Threading.DispatcherObject
      System.Windows.DependencyObject
         System.Windows.Freezable
            System.Windows.Media.Animation.Animatable
               System.Windows.Media.Effects.BitmapEffect
                  Leadtools.Windows.Media.Effects.RasterCommandBitmapEffect
                     Leadtools.Windows.Media.Effects.Color.SampleTargetCommandBitmapEffect

Requirements

Target Platforms: Microsoft .NET Framework 2.0, Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also