简体   繁体   中英

WebAssembly include OpenCV

I have C++ code that manipulates images with OpenCV and I'd like to compile it with emscripten . But emscripten doesn't find OpenCV if i type:

em++ test.c -s WASM=1 -O3 -o test.js -lopencv_highgu

The warning i get:

WARNING:root:emcc: cannot find library "opencv_highgui"

I guess emscripten doesn't use my normal include path. So the question is how can i compile my C++/OpenCV program to WebAssembly

You'd first have to compile the entire OpenCV library to WebAssembly and then include it in your project. Here is some additional information: https://hacks.mozilla.org/2017/09/bootcamps-webassembly-and-computer-vision/

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM