title: Text Recognition with RNCamera
body: <p>I'm trying to develop a ReactNative app which uses RNCamera, along with other libraries like react-navigation. Here are the dependencies and their versions that I am using:</p>
  <pre><code>&quot;@react-native-community/masked-view&quot;: &quot;^0.1.10&quot;,
  &quot;react&quot;: &quot;16.13.1&quot;,
  &quot;react-native&quot;: &quot;0.63.4&quot;,
  &quot;react-native-camera&quot;: &quot;^3.42.0&quot;,
  &quot;react-native-cli&quot;: &quot;^2.0.1&quot;,
  &quot;react-native-gesture-handler&quot;: &quot;^1.9.0&quot;,
  &quot;react-native-reanimated&quot;: &quot;^1.13.2&quot;,
  &quot;react-native-safe-area-context&quot;: &quot;^3.1.9&quot;,
  &quot;react-native-screens&quot;: &quot;^2.16.1&quot;,
  &quot;react-navigation&quot;: &quot;^4.4.3&quot;,
  &quot;react-navigation-stack&quot;: &quot;^2.10.2&quot;
  </code></pre>
  <p>Everything is working just fine, but the problem is that I want to use the live text recognition which does not give me the results expected. This is the code I am using:</p>
  <pre><code>import React, { useState } from 'react';
  import { StyleSheet, Text, View } from 'react-native';
  import {RNCamera} from 'react-native-camera';
  
  const CameraScreen = ({navigation}) =&gt; {
  
    state = {
        recordOptions: {
            mute: false,
            maxDuration: 5,
            quality: RNCamera.Constants.VideoQuality['288p'],
        }
    };
  
    return (
        &lt;RNCamera
            ref={ref =&gt; {
              camera = ref;
            }}
            style={{
              flex: 1,
              width: '100%',
            }}
            type={'back'}
            flashMode={'off'}
            autoFocus={'on'}
            zoom={0}
            whiteBalance={'auto'}
            ratio={'16:9'}
            focusDepth={0}
            trackingEnabled
            androidCameraPermissionOptions={{
                        title: 'Permission to use camera',
                        message: 'We need your permission to use your camera',
                        buttonPositive: 'Ok',
                        buttonNegative: 'Cancel',
            }}
  
            onTextRecognized={({text})=&gt;{console.log(text)}}
        &gt;&lt;/RNCamera&gt;
    );
  };
  
  const styles = StyleSheet.create({});
  
  export default CameraScreen;
  </code></pre>
  <p>As you can see, I call an console.log function for onTextRecognized, which is triggered every few milliseconds. What happens is that I am constantly reciving the text 'undefined', which does not change even if I put text in front of the camera for a minute. This is the logs I got (it can be seen that logs appear every few milliseconds):</p>
  <p><a href="https://i.stack.imgur.com/lcPjV.png" rel="nofollow noreferrer">logs file</a></p>
  <p>Does anybody know how can I get the text without taking a picture?
  I also have tried to add 'textBlocks' from other tutorials but I can't make it work (please tell me if you also know how to do this).</p>