←Select platform

UnWarpCommand Class

Summary
Removes the distortion in an image of a cylindrical object, as if removing a label from off of the cylinder and flattening it out.
Syntax
C#
Objective-C
C++/CLI
Java
Python
public class UnWarpCommand : RasterCommand 
@interface LTUnWarpCommand : LTRasterCommand 
public class UnWarpCommand 
    extends RasterCommand 
public ref class UnWarpCommand : public RasterCommand, System.IDisposable   
class UnWarpCommand(RasterCommand): 
Remarks

Typically, this command is used in preprocessing images from digital cameras. This command requires an array of 8 points. An Invalid Parameters Exception will be thrown if no array of 8 points is passed. The following image shows the use of this function to flatten a label from a pill bottle. The numbers on the label represent the points in the array. The four corners (1, 2, 3, and 4) are fixed points in this command. The interior points on the label (5, 6, 7, and 8) are the ones that are moved to flatten the image.

unwarp.png

Notes:

  • Use the UnWarpCommand if the image contains a distortion of a cylindrical object. Use the ManualPerspectiveDeskewCommand, PerspectiveDeskewCommand or KeyStoneCommand if there is a planar deformation along all three axes. Use the DeskewCommand if there is deformation along the x- and y- axes.
  • Use the Run method to fix the distorted image. Obtain the processed image from the OutputImage property.
  • This command supports 24-bit and 36-bit color images, 8-bit grayscale images, and 1-bit binarized images.
  • This command supports signed/unsigned images.

UnWarp Function - Before

UnWarp Function - Before

UnWarp Function - After

UnWarp Function - After

View additional platform support for this UnWarp function.

Requirements

Target Platforms

Help Version 23.0.2024.3.3
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2024 LEAD Technologies, Inc. All Rights Reserved.

Leadtools.ImageProcessing.Core Assembly
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.