L_Doc2AutoOrientPage
#include "ltdoc2.h"
L_LTDOC2_API L_INT EXT_FUNCTION L_Doc2AutoOrientPage(hDoc, nPageIndex)
L_HDOC2 hDoc; |
/* handle to the OCR document */ |
L_INT nPageIndex; |
/* page index */ |
Auto orients the specified page.
Parameter |
Description |
hDoc |
Handle to the OCR document. |
nPageIndex |
Index of the page to auto orient. This is a zero-based index. |
Returns
SUCCESS |
The function was successful. |
< 1 |
An error occurred. Refer to Return Codes. |
Comments
This function automatically orients (rotates) the specified page to be readable and updates the image data. Use the L_Doc2DetectOrientationDegree function if you just want to obtain the angle of orientation, without orienting the page.
Required DLLs and Libraries
LTDOC2 For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application. |
See Also
Functions: |
L_Doc2AddPage, L_Doc2GetPageCount, L_Doc2RemovePage, L_Doc2ExportPage, L_Doc2UpdatePage, L_Doc2GetPageInfo, L_Doc2CleanupPages |
Topics: |
|
|
Example
L_LTDOC2TEX_API L_INT Doc2AutoOrientPageExample(L_HDOC2 hDoc,L_INT nPageIndex) { L_INT nRet; nRet = L_Doc2AutoOrientPage(hDoc, nPageIndex); if (nRet != SUCCESS) { MessageBox(NULL, TEXT("Failure while auto orienting the current page"), TEXT("Notice!"), MB_OK); return nRet; } return SUCCESS; }