Leadtools.ImageProcessing.Core Send comments on this topic. | Back to Introduction - All Topics | Help Version 15.12.10
ResizeInterpolateCommand Constructor(Int32,Int32,ResizeInterpolateCommandType)
See Also  Example
Leadtools.ImageProcessing.Core Namespace > ResizeInterpolateCommand Class > ResizeInterpolateCommand Constructor : ResizeInterpolateCommand Constructor(Int32,Int32,ResizeInterpolateCommandType)




width
Value that represents the desired image's width in pixels.
height
Value that represents the desired image's height in pixels.
resizeType
Value that represents the algorithm type used in resizing the image. For possible values refere to ResizeInterpolateCommandType.
Initializes a new instance of ResizeInterpolateCommand class with explicit parameters.

Syntax

Visual Basic (Declaration) 
Public Function New( _
   ByVal width As Integer, _
   ByVal height As Integer, _
   ByVal resizeType As ResizeInterpolateCommandType _
)
Visual Basic (Usage)Copy Code
Dim width As Integer
Dim height As Integer
Dim resizeType As ResizeInterpolateCommandType
 
Dim instance As ResizeInterpolateCommand(width, height, resizeType)
C# 
public ResizeInterpolateCommand( 
   int width,
   int height,
   ResizeInterpolateCommandType resizeType
)
Managed Extensions for C++ 
public: ResizeInterpolateCommand( 
   int width,
   int height,
   ResizeInterpolateCommandType resizeType
)
C++/CLI 
public:
ResizeInterpolateCommand( 
   int width,
   int height,
   ResizeInterpolateCommandType resizeType
)

Parameters

width
Value that represents the desired image's width in pixels.
height
Value that represents the desired image's height in pixels.
resizeType
Value that represents the algorithm type used in resizing the image. For possible values refere to ResizeInterpolateCommandType.

Example

Visual BasicCopy Code
ImageProcessing.Core.ResizeInterpolateCommand.ResizeConstructor
   Public Sub ResizeConstructorExample()
      RasterCodecs.Startup()
      Dim codecs As New RasterCodecs()
      codecs.ThrowExceptionsOnInvalidImages = True

      Dim leadImage As RasterImage = codecs.Load("C:\Program Files\LEAD Technologies\LEADTOOLS 15\Images\Master.jpg")

      ' Prepare the command
      ' Resize the bitmap into 50 pixels x 50 pixels using the Bilinear algorithm.
      Dim command As ResizeInterpolateCommand = New ResizeInterpolateCommand(50, 50, ResizeInterpolateCommandType.Bilinear)
      command.Run(leadImage)

      RasterCodecs.Shutdown()
   End Sub
C#Copy Code
ImageProcessing.Core.ResizeInterpolateCommand.ResizeConstructor 
      public void ResizeConstructorExample() 
      { 
         // Load an image 
         RasterCodecs.Startup(); 
         RasterCodecs codecs = new RasterCodecs(); 
         codecs.ThrowExceptionsOnInvalidImages = true; 
 
         RasterImage image = codecs.Load(@"C:\Program Files\LEAD Technologies\LEADTOOLS 15\Images\Master.jpg"); 
 
         // Prepare the command 
         // Resize the bitmap into 50 pixels x 50 pixels using the Bilinear algorithm. 
         ResizeInterpolateCommand command = new ResizeInterpolateCommand(50, 50, ResizeInterpolateCommandType.Bilinear); 
         command.Run(image); 
 
         RasterCodecs.Shutdown(); 
      }

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