SimpleOCR:SDK Functions – HalfSizeImg

You are here:
< All Topics

IMG * HalfSizeImg(IMG * img)

Shrinks a bi-level image at 50% of the original size and returns the result in a grayscale image.

Return Value

A pointer to a new IMG object. If the function fails, the return value is NULL.



Pointer to an image of type IMG.


The original image is left unchanged. If you don’t need it anymore, you have to free it by calling the FREEIMG function. This function is mainly useful when you want to display a reduced bi-level image with a good display quality.


IMG *img,img2; 

// Create an IMG 

if (img2==NULL) 
// Error processing 
Previous SimpleOCR:SDK Functions – GetNbImages
Next SimpleOCR:SDK Functions – InsertImage
Contact Us for FREE Consultation on Your OCR Project
Table of Contents


Go to Top