Text Recognizer : Extract Text From Images

What is Text Recognition ?

Text recognition is the process of detecting text in images and video streams and recognizing the text contained therein. Once detected, the recognizer then determines the actual text in each block and segments it into lines and words
So in this tutorial i will design the Text Recognition by using the Google Cloud Vision API




Firstly, we need to add Dependency of Google Cloud Vision API in the app/build.gradle file



After placing Dependency I Place google vision API dependencies meta-data tag in the Application Tag in AndroidManifest.xml file

After placing Meta-data tag in the Manifest file then come to activity_main.xml and add the ImageView for showing the image and add the Two Button one for "Pick Up Image" and another one for "Recognize Text" 


 
Now Create Another Activity "activity_text_display.xml" for showing the recognized text from the image



Then implement Recognition functionality in MainActivity.java like Open Intent for choosing image from gallery and Pass the Recognized text to Another Activity named TextDisplay.java

MainActivity.java

TextDisplay.java

Written By : Tushar Verma
Source Code Github :  https://github.com/tushar821999/Text_Recognizer
Linkedin Profile : https://www.linkedin.com/in/tushar-verma-047329154/ 


If you have an query related to this tutorial let me know in the comment section

1 Comments

Post a comment

Previous Post Next Post