Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

motion-ocr

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

motion-ocr

  • 0.1.0
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

MotionOCR

A RubyMotion wrapper for the OCR engine Tesseract.

Installation

First, install the gem:

gem install motion-ocr

Then, reference it in your RubyMotion project Rakefile:

# -*- coding: utf-8 -*-
$:.unshift("/Library/RubyMotion/lib")
require 'motion/project/template/ios'

require 'motion-ocr'

And that's it. Build your project and MotionOCR will be ready for action.

Use

ocr             = Motion::OCR.new
image_with_text = UIImage.imageNamed('phototest.gif').CGImage

ocr.scan(image_with_text) # returns a String containing the detected text in the image

Options

You use your own Tesseract language file (available at https://code.google.com/p/tesseract-ocr/downloads/list).

Put the language file (e.g., spa.traineddata) into your app's ressources/tessdata directory. Then pass the language to MotionOCR:

ocr = Motion::OCR.new language: 'spa'

FAQs

Package last updated on 09 Oct 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc