Sha256: 3502efff0352d3ee9e2e413715d00eb8c4c2b2a7223b87f2cd57da99c10211b2
Contents?: true
Size: 514 Bytes
Versions: 8
Compression:
Stored size: 514 Bytes
Contents
module OcrFile module OcrEngines module Tesseract extend self def id 'tesseract' end def ocr_to_text(file_path, options: {}) image = ::RTesseract.new(file_path) image.to_s # Getting the value end def ocr_to_pdf(file_path, options: {}) image = ::RTesseract.new(file_path) raw_output = image.to_pdf # Getting open file of pdf OcrFile::ImageEngines::PdfEngine.open_pdf(raw_output, password: '') end end end end
Version data entries
8 entries across 8 versions & 1 rubygems