Notice: This documentation is archived. For the latest product features and documentation, please visit Dynamsoft Capture Vision Documentation.
CNormalizedImageResult Class
Stores the normalized image result.
class dynamsoft::ddn::CNormalizedImageResult
Method | Description |
---|---|
GetImageData |
Gets the image data of the NormalizedImageResult. |
SaveToFile |
Save the normalized image result to a file. |
GetImageData
Gets the image data of the NormalizedImageResult.
const CImageData* GetImageData()
Return Value
The image data.
SaveToFile
Save the image data to a file.
int dynamsoft::ddn::CDocumentNormalizer::SaveToFile(const char* filePath)
Parameters
[in] filePath
The path of the output image file with the extension specifying the image format. It supports BMP, PNG, JPEG and PDF file types. If the target file exists, the image will be appended to the last page of the PDF file while the BMP, PNG and JPEG file will be replaced.
Return Value
Returns error code (returns 0 if the function operates successfully).
You can call DC_GetErrorString
to get detailed error message.
Code Snippet
CDocumentNormalizer ddn;
CNormalizedImageResult* normalizedResult = NULL;
ddn.Normalize("YOUR-SOURCE-FILE-PATH", "", NULL, &normalizedResult);
if (normalizedResult != NULL)
{
normalizedResult->SaveToFile("YOUR-TARGET-FILE-PATH");
CDocumentNormalizer::FreeNormalizedImageResult(&normalizedResult);
}