Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can anybody generate opencv.js?

I can't generate OpenCV.js using this instructions: https://docs.opencv.org/master/d4/da1/tutorial_js_setup.html

I have this error:

CMake Error: CMake was unable to find a build program corresponding to "Unix Makefiles". CMAKE_MAKE_PROGRAM is not set. You probably need to select a different build tool.

When I'm trying to execute:

python ./platforms/js/build_js.py build_js

Alright, guys! You can download opencv.js from sources (press F12) of this Page: https://docs.opencv.org/master/js_face_detection_camera.html

like image 938
Игорь Токарев Avatar asked Apr 11 '18 14:04

Игорь Токарев


People also ask

Can I use OpenCV in js?

As a multi-platform library, OpenCV can be used with an extensive number of languages including, of course, Javascript.

Where can I download OpenCV js?

You can get a copy of opencv. js from opencv-{VERSION_NUMBER}-docs. zip in each release, or simply download the prebuilt script from the online documentations at "https://docs.opencv.org/{VERSION_NUMBER}/opencv.js" (For example, https://docs.opencv.org/4.5.0/opencv.js.

Can we use OpenCV in browser?

OpenCV is a powerful library used for image processing, analysis and image recognition. It has been used extensively in many fields, from face detection to interactive art. With opencv. js it's possible to do image processing, video analysis and object detection in the browser!

Who makes OpenCV?

OpenCV (Open Source Computer Vision Library) is a library of programming functions mainly aimed at real-time computer vision. Originally developed by Intel, it was later supported by Willow Garage then Itseez (which was later acquired by Intel).


2 Answers

Looks like Emscripten doesn't setup the enviroment variable correctly to the SDK

For anyone trying to get this to build you need to specify the correct path to the Emscripten

which is the path where Emscripten is installed found in emsdk/upstream/emscripten

python ./platforms/js/build_js.py build_js --emscripten_dir=/home/username/Desktop/emsdk/upstream/emscripten

This should then work

like image 190
Feroz Avatar answered Sep 24 '22 18:09

Feroz


You can find a nightly build at https://docs.opencv.org/master/opencv.js and some useful stuff at https://docs.opencv.org/master/utils.js .

<script async src="https://docs.opencv.org/master/opencv.js" type="text/javascript"></script>
like image 38
Dmitry Kurtaev Avatar answered Sep 23 '22 18:09

Dmitry Kurtaev