Comments (6)
What if you parse the OpenCV API Docs and generate the entire api?
A quick search found some other people looking for the same thing over in peterbraden/node-opencv#290.
Great ideas here: http://answers.opencv.org/question/6618/how-python-api-is-generated/
Also, this project looks interesting: https://github.com/charto/nbind. But I have never tried it out.
from opencv4nodejs.
I don't think using emscripten/asm is a good idea. Rather, its about generating the bindings from the c code.
The opencv python bindings are generated by parsing the c/cpp headers, and then using some string templates as explained in the answers.opencv.org link.
In the opencv codebase there is some interesting stuff in opencv/modules/{js,python,ts}
.
from opencv4nodejs.
Alright. Only moveWindow?
from opencv4nodejs.
For now that was just one function I wanted to use that wasn't available.
I'm wondering if there is not a more automated way to easily implement all the methods?
from opencv4nodejs.
Nothing that I am aware of, not for nodejs bindings. There is an approach, which compiles some OpenCV modules to pure javascript via LLVM using emscripten, but the goal of opencv4nodejs is to provide native performance, easy multithreading, async methods and an comfortable to use API.
Implementing the bindings is actually not that hard, the main issue is, you have to know the OpenCV modules, for which you want to add bindings.
from opencv4nodejs.
I think that's what I was talking about by compiling it to asm.js using emscripten. Haven't tried any of them yet, but as far as I know asm.js has still considerably less performance than native, maybe that might change with webassembly in future.
However I am also not sure, if it is possible to achieve async methods and multiple workers that way and how one would generate these, but I don't know asm.js well enough. I'm gonna have a look at your links, thanks for sharing.
from opencv4nodejs.
Related Issues (20)
- [!] RollupError: Could not resolve "../build/Release/opencv4nodejs.node" from "../build/Release/opencv4nodejs.node?commonjs-external" HOT 1
- Cannot find module 'C:\Users\pierr\Desktop\onnxjs\node_modules\opencv4nodejs\build\Release\opencv4nodejs' HOT 2
- Imencode - OpenCV Error: (!image.empty()) in imencode, in file... RPI4 HOT 1
- Correct the state of the `opencv4nodejs` package on the NPM. HOT 5
- canot load opencv4nodejs after install HOT 1
- Cannot find module 'D:\Web\opencv\node_modules\opencv4nodejs\build\Release\opencv4nodejs' HOT 2
- Error: CalcHist - object has no property: ranges HOT 1
- Can't resolve '../build/Release/opencv4nodejs.node' HOT 1
- Cannot find module /node_modules/@u4/opencv4nodejs/build/Release/opencv4nodejs'
- why no cv.compare or mat.compare function?
- how to catch mouse event on imshow
- ar
- Type error with mat.drawCountours()
- Unable to install opencv4nodejs HOT 1
- Unable to install in Ubuntu 22.05
- Ssim library
- Issues with node-gyp
- Issue with cv.Mat
- Issue with importing cv
- I think that typescript-eslint and eslint should be moved in the dev-dependencies. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from opencv4nodejs.