fn detect_text(
        &self,
        input: DetectTextRequest,
    ) -> RusotoFuture<DetectTextResponse, DetectTextError> {
        let mut request = SignedRequest::new("POST", "rekognition", &self.region, "/");

        request.set_content_type("application/x-amz-json-1.1".to_owned());
        request.add_header("x-amz-target", "RekognitionService.DetectText");
        let encoded = serde_json::to_string(&input).unwrap();
        request.set_payload(Some(encoded.into_bytes()));

        self.client.sign_and_dispatch(request, |response| {
            if response.status.is_success() {
                Box::new(response.buffer().from_err().map(|response| {
                    let mut body = response.body;

                    if body.is_empty() || body == b"null" {
                        body = b"{}".to_vec();
                    }

                    serde_json::from_str::<DetectTextResponse>(
                        String::from_utf8_lossy(body.as_ref()).as_ref(),
                    )
                    .unwrap()
                }))
            } else {
                Box::new(
                    response
                        .buffer()
                        .from_err()
                        .and_then(|response| Err(DetectTextError::from_response(response))),
                )
            }
        })
    }
/// <p>Detects text in the input image and converts it into machine-readable text.</p> <p>Pass the input image as base64-encoded image bytes or as a reference to an image in an Amazon S3 bucket. If you use the AWS CLI to call Amazon Rekognition operations, you must pass it as a reference to an image in an Amazon S3 bucket. For the AWS CLI, passing image bytes is not supported. The image must be either a .png or .jpeg formatted file. </p> <p>The <code>DetectText</code> operation returns text in an array of elements, <code>TextDetections</code>. Each <code>TextDetection</code> element provides information about a single word or line of text that was detected in the image. </p> <p>A word is one or more ISO basic latin script characters that are not separated by spaces. <code>DetectText</code> can detect up to 50 words in an image.</p> <p>A line is a string of equally spaced words. A line isn't necessarily a complete sentence. For example, a driver's license number is detected as a line. A line ends when there is no aligned text after it. Also, a line ends when there is a large gap between words, relative to the length of the words. This means, depending on the gap between words, Amazon Rekognition may detect multiple lines in text aligned in the same direction. Periods don't represent the end of a line. If a sentence spans multiple lines, the <code>DetectText</code> operation returns multiple lines.</p> <p>To determine whether a <code>TextDetection</code> element is a line of text or a word, use the <code>TextDetection</code> object <code>Type</code> field. </p> <p>To be detected, text must be within +/- 30 degrees orientation of the horizontal axis.</p> <p>For more information, see DetectText in the Amazon Rekognition Developer Guide.</p>
Detects text in the input image and converts it into machine-readable text. Pass the input image as base64-encoded image bytes or as a reference to an image in an Amazon S3 bucket. If you use the AWS CLI to call Amazon Rekognition operations, you must pass it as a reference to an image in an Amazon S3 bucket. For the AWS CLI, passing image bytes is not supported. The image must be either a .png or .jpeg formatted file.  The DetectText operation returns text in an array of elements, TextDetections. Each TextDetection element provides information about a single word or line of text that was detected in the image.  A word is one or more ISO basic latin script characters that are not separated by spaces. DetectText can detect up to 50 words in an image. A line is a string of equally spaced words. A line isn't necessarily a complete sentence. For example, a driver's license number is detected as a line. A line ends when there is no aligned text after it. Also, a line ends when there is a large gap between words, relative to the length of the words. This means, depending on the gap between words, Amazon Rekognition may detect multiple lines in text aligned in the same direction. Periods don't represent the end of a line. If a sentence spans multiple lines, the DetectText operation returns multiple lines. To determine whether a TextDetection element is a line of text or a word, use the TextDetection object Type field.  To be detected, text must be within +/- 30 degrees orientation of the horizontal axis. For more information, see DetectText in the Amazon Rekognition Developer Guide.
Detects text in the input image and converts it into machine - readable text . Pass the input image as base64 - encoded image bytes or as a reference to an image in an Amazon S3 bucket . If you use the AWS CLI to call Amazon Rekognition operations you must pass it as a reference to an image in an Amazon S3 bucket . For the AWS CLI passing image bytes is not supported . The image must be either a . png or . jpeg formatted file . The DetectText operation returns text in an array of elements TextDetections . Each TextDetection element provides information about a single word or line of text that was detected in the image . A word is one or more ISO basic latin script characters that are not separated by spaces . DetectText can detect up to 50 words in an image . A line is a string of equally spaced words . A line isn ' t necessarily a complete sentence . For example a driver ' s license number is detected as a line . A line ends when there is no aligned text after it . Also a line ends when there is a large gap between words relative to the length of the words . This means depending on the gap between words Amazon Rekognition may detect multiple lines in text aligned in the same direction . Periods don ' t represent the end of a line . If a sentence spans multiple lines the DetectText operation returns multiple lines . To determine whether a TextDetection element is a line of text or a word use the TextDetection object Type field . To be detected text must be within + / - 30 degrees orientation of the horizontal axis . For more information see DetectText in the Amazon Rekognition Developer Guide .
fn detect_text(
        &self,
        input: DetectTextRequest,
    ) -> RusotoFuture<DetectTextResponse, DetectTextError> {
        let mut request = SignedRequest::new("POST", "rekognition", &self.region, "/");
        request.set_content_type("application/x-amz-json-1.1".to_owned());
        request.add_header("x-amz-target", "RekognitionService.DetectText");
        let encoded = serde_json::to_string(&input).unwrap();
        request.set_payload(Some(encoded.into_bytes()));
        self.client.sign_and_dispatch(request, |response| {
            if response.status.is_success() {
                Box::new(response.buffer().from_err().map(|response| {
                    let mut body = response.body;
                    if body.is_empty() || body == b"null" {
                        body = b"{}".to_vec();
                    }
                    serde_json::from_str::<DetectTextResponse>(
                        String::from_utf8_lossy(body.as_ref()).as_ref(),
                    )
                    .unwrap()
                }))
            } else {
                Box::new(
                    response
                        .buffer()
                        .from_err()
                        .and_then(|response| Err(DetectTextError::from_response(response))),
                )
            }
        })
    }
fn detect_text ( & self , input : DetectTextRequest , ) -> RusotoFuture < DetectTextResponse , DetectTextError > { let mut request = SignedRequest :: new ( " " , " " , & self . region , " " ) ; request . set_content_type ( " " . to_owned ( ) ) ; request . add_header ( " " , " " ) ; let encoded = serde_json :: to_string ( & input ) . unwrap ( ) ; request . set_payload ( Some ( encoded . into_bytes ( ) ) ) ; self . client . sign_and_dispatch ( request , | response | { if response . status . is_success ( ) { Box :: new ( response . buffer ( ) . from_err ( ) . map ( | response | { let mut body = response . body ; if body . is_empty ( ) || body == b" " { body = b" " . to_vec ( ) ; } serde_json :: from_str :: < DetectTextResponse > ( String :: from_utf8_lossy ( body . as_ref ( ) ) . as_ref ( ) , ) . unwrap ( ) } ) ) } else { Box :: new ( response . buffer ( ) . from_err ( ) . and_then ( | response | Err ( DetectTextError :: from_response ( response ) ) ) , ) } } ) }
<p>Detects text in the input image and converts it into machine-readable text.</p> <p>Pass the input image as base64-encoded image bytes or as a reference to an image in an Amazon S3 bucket.
<p > Detects text in the input image and converts it into machine - readable text . < / p > <p > Pass the input image as base64 - encoded image bytes or as a reference to an image in an Amazon S3 bucket .
&self
input
DetectTextRequest
&self
input
DetectTextRequest