Gets the parameters that were used for the last LBitmapBase::Rotate or LBitmapBase::RotateViewPerspective call.
#include "ltwrappr.h"
L_VOID LBitmapBase::GetRotateParams(nAngle, bResize, pOldCenter)
Hundredths of degrees to rotate (+/-). This can be a number from 0 to 36,000. A positive value will rotate the image in a clockwise rotation, while a negative value will rotate the image in a counter-clockwise rotation.
TRUE if the image was also resized, FALSE if the dimensions were not altered.
The center point that was used for the rotation. Normally, this is the images center point.
Value | Meaning |
---|---|
SUCCESS | The function was successful. |
< 1 | An error occurred. Refer to Return Codes. |
Bitmaps might be rotated by user interaction within the LAnnotationWindow class. This function can be used to get the parameters that were specified when that rotation occurred.
Win32, x64.
class MyBitmapBase : public LBitmapBase {
public:
L_VOID MyGetRotateParams( L_INT32 * nAngle, L_BOOL *bResize, pANNPOINT pOldCenter)
{
this->GetRotateParams(nAngle,bResize,pOldCenter);
}
};
L_INT LBitmapBase__GetRotateParamsExample()
{
L_INT nRet;
MyBitmapBase LeadBitmap; /* Bitmap handle to hold the loaded image. */
pBITMAPHANDLE pLeadBitmapHandle = LeadBitmap.GetHandle();
/* Load the bitmap, keeping the bits per pixel of the file */
nRet = LeadBitmap.Load(MAKE_IMAGE_PATH(TEXT("IMAGE1.CMP")), 0, ORDER_BGR);
if(nRet !=SUCCESS)
return nRet;
L_INT32 nAngle; /* hundredths of degreesto rotate (+/-) */
L_BOOL bResize; /* resize flag */
ANNPOINT OldCenter; /* rotation center point */
LeadBitmap.MyGetRotateParams(&nAngle, &bResize, &OldCenter);
//free bitmap
if(pLeadBitmapHandle->Flags.Allocated)
L_FreeBitmap(pLeadBitmapHandle);
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