antimatter15 / ocrad.js

OCR in Javascript via Emscripten
http://antimatter15.github.io/ocrad.js/demo.html
GNU General Public License v3.0
3.49k stars 389 forks source link

Won't work when uploading image with bigger file size #39

Open jituraiyan opened 6 years ago

jituraiyan commented 6 years ago

24_ap3 5_st1by8_iso800

It woks pretty well for images which is not big size. but when I upload this image (4.32 MB) Then it sjow me this errors:

Cannot enlarge memory arrays. Either (1) compile with -s TOTAL_MEMORY=X with X higher than the current value 33554432, (2) compile with -s ALLOW_MEMORY_GROWTH=1 which adjusts the size at runtime but prevents some optimizations, (3) set Module.TOTAL_MEMORY to a higher value before the program runs, or if you want malloc to return NULL (0) instead of this abort, compile with -s ABORTING_MALLOC=0 ocrad.min.js:12

Cannot enlarge memory arrays. Either (1) compile with -s TOTAL_MEMORY=X with X higher than the current value 33554432, (2) compile with -s ALLOW_MEMORY_GROWTH=1 which adjusts the size at runtime but prevents some optimizations, (3) set Module.TOTAL_MEMORY to a higher value before the program runs, or if you want malloc to return NULL (0) instead of this abort, compile with -s ABORTING_MALLOC=0 ocrad.min.js:12

warning: build with -s DEMANGLE_SUPPORT=1 to link in libcxxabi demangling ocrad.min.js:12

customautosys commented 6 years ago

Hi, I am facing a similar problem. How do I make it expand memory? I cannot even open any PDF file at all and I need to read several pages of text each time at least.