Moves the corners of the class object's bitmap in the fashion of a parallelogram.
#include "ltwrappr.h"
virtual L_INT LBitmapBase::Shear(nAngle, bHorizontal=TRUE, crFill=0)
The angle of slant. Positive values are for clockwise angles; negative values are for counterclockwise angles. The angle is expressed in hundredths of degrees, with a limit of 4500 (45 degrees).
Flag that indicates the direction of the shear. Possible values are:
Value | Meaning |
---|---|
TRUE | Horizontal shear. |
FALSE | Vertical shear. |
The COLORREF value that specifies the fill color. You can specify a COLORREF value, such as the return value of the Windows RGB macro, or you can use the PALETTEINDEX macro to specify a palette color.
Value | Meaning |
---|---|
SUCCESS | The function was successful. |
< 1 | An error occurred. Refer to Return Codes. |
You specify an angle of slant, horizontal or vertical shear, and the fill color for the created space. The following is a horizontal example:
The angle is expressed in hundredths of degrees, with a limit of 4500 (45 degrees).
To update a status bar or detect a user interrupt during execution of this function, refer to LBase::EnableStatusCallBack.
This function does not support signed data images. It returns the error code ERROR_SIGNED_DATA_NOT_SUPPORTED if a signed data image is passed to this function.
Shear Function - Before
Shear Function - After
View additional platform support for this Shear function.
Win32, x64.
L_INT LBitmapBase__ShearExample()
{
L_INT nRet;
LBitmapBase MyBitmap;
MyBitmap.SetFileName(MAKE_IMAGE_PATH(TEXT("image1.cmp")));
nRet =MyBitmap.Load();
if(nRet !=SUCCESS)
return nRet;
nRet =MyBitmap.Shear(2200,FALSE, RGB(220,120,220));
if(nRet !=SUCCESS)
return nRet;
return SUCCESS;
}
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document