Skip to content

Instantly share code, notes, and snippets.

@justinyoo
Created March 27, 2017 15:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save justinyoo/45ad73af4bb30f6ec02989ac96d190e9 to your computer and use it in GitHub Desktop.
Save justinyoo/45ad73af4bb30f6ec02989ac96d190e9 to your computer and use it in GitHub Desktop.
Implementing OCR Using Azure Cognitive Services with HTML5 Media Capture API
<template>
<div>
<div class="image-input">
<input type="file" id="ocr-input" accept="image/*" capture="camera" ref="ocrInput" />
<button type="button" v-on:click="getText">Submit</button>
</div>
<div class="image-output">
<img id="ocr-image" ref="ocrOutput" style="width:300px" />
</div>
<div class="cognitive-result">
<textarea id="ocr-result" style="width: 300px; height: 200px;" ref="ocrResult"></textarea>
</div>
</div>
</template>
<script lang="ts">
import Ocr from "./Ocr.ts";
export default Ocr;
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment