Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Windows 10] Unable to require opencv4nodejs - Error: The specified module could not be found. #84

Closed
mcolomerc opened this issue Nov 27, 2017 · 2 comments

Comments

@mcolomerc
Copy link

OS: Windows 10
NodeJS: v9.2.0
NPM: 5.5.1
node-gyp: node-gyp@3.6.2
windows-build-tools@1.3.2
OpenCV: opencv-3.3.1-vc14

The Build was done, with some warnings, but the following error was thrown when I tried to run the examples or when I tried to do a require:

const cv = require('opencv4nodejs');

$ node index.js
module.js:670
  return process.dlopen(module, path.toNamespacedPath(filename));
                 ^

Error: The specified module could not be found.
\\?\C:\Users\myUser\opencv4nodejs\build\Release\opencv4nodejs.node
    at Object.Module._extensions..node (module.js:670:18)
    at Module.load (module.js:560:32)
    at tryModuleLoad (module.js:503:12)
    at Function.Module._load (module.js:495:3)
    at Module.require (module.js:585:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (C:\Users\muUser\opencv4nodejs\index.js:1:74)
    at Module._compile (module.js:641:30)
    at Object.Module._extensions..js (module.js:652:10)
    at Module.load (module.js:560:32)
@justadudewhohacks
Copy link
Owner

Hey marcelogft,

It means you are missing the opencv binaries in your system path. See #50

@mcolomerc
Copy link
Author

Thanks.
It was an error with:
OPENCV_DIR=C:\Users\myUser\opencv\build\x64\vc14\bin

I changed to OPENCV_DIR=C:\Users\myUser\opencv\build\x64\vc14 and now it works!

Thanks!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants