Mork ==== A ruby [optical mark recognition](http://en.wikipedia.org/wiki/Optical_mark_recognition) (OMR) library to accomplish two tasks: 1. generating [response sheets](/spec/samples/sheet1.pdf) in PDF format (for tests, surveys, etc.) 2. capturing the responses provided on the [printed sheet](/spec/samples/sheet1.jpg) by a human with a pen or a pencil. Assumptions and limitations --------------------------- Mork is a low-level library, and very much work in progress. It is not, and will likely never be a complete OMR solution. While suggestions and contributions are more than welcome, for the time being several assumptions and restrictions to what the library is capable of apply. - the generated PDF file is intended to be printed on regular printer paper, and the filled-out form to be acquired as a bitmap image by a normal optical scanner or camera (i.e., no specialized equipment is necessary) - the [response sheet](/spec/samples/sheet1.pdf) contains the following items: - registration marks at each page corner - a bar code along the bottom margin to uniquely identify the sheet - a header area to print arbitrary information - a response area containing a list of numbered items (questions) - each item contains an arbitrary number of choices, each marked with a capital letter (A, B, C, ...). In order to maximize contrast, choice "cells" are printed in red - with some restrictions, the number of columns in the response area, the numer of items, the number of choices per item, the size and shape of the choice cells can be set by the user - all items must fit within the allocated response area of a single sheet Installing ---------- Install the gem in your system: $ gem install mork If you are using bundler in your project, as you should, make sure your `Gemfile` contains the following, before running `bundle install`: source 'http://rubygems.org' gem 'mork' Usage ----- The layout of the response sheet is described in a YAML file License ------- Copyright (c) 2013 Giuseppe Bertini Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.