As @jonathan points out the image needs to be referenced.
The simpliest way to get this to work with the current example is to just use the Hype getElementProperty API to get the path to the background image.
var img = hypeDocument.getElementById("chip4");
var imagBG = hypeDocument.getElementProperty(img, 'background-image')
Tesseract.recognize(imagBG)
.progress(function (p) { console.log('progress', p) })
.then(function (result) { console.log('result', result) })
var img = hypeDocument.getElementById("chip4");
var imagBG = hypeDocument.getElementProperty(img, 'background-image')
var resultOCR_ = hypeDocument.getElementById("resultOCR");
Tesseract.recognize(imagBG)
.progress(function (p) { console.log('progress', p)
resultOCR_.innerHTML = p.status
})
.then(function (result) { console.log('result', result)
resultOCR_.innerHTML = result.text
})
ocrTest_mhv1.hype.zip (217.3 KB)