Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rainyl/opencv_dart
OpenCV bindings for Dart language and Flutter. Support Asynchronous Now!
https://github.com/rainyl/opencv_dart
dart ffi flutter opencv opencv4
Last synced: 2 days ago
JSON representation
OpenCV bindings for Dart language and Flutter. Support Asynchronous Now!
- Host: GitHub
- URL: https://github.com/rainyl/opencv_dart
- Owner: rainyl
- License: apache-2.0
- Created: 2024-02-03T05:32:56.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-01-22T12:53:22.000Z (12 days ago)
- Last Synced: 2025-01-25T14:06:30.918Z (9 days ago)
- Topics: dart, ffi, flutter, opencv, opencv4
- Language: Dart
- Homepage: https://pub.dev/packages/opencv_dart
- Size: 16.8 MB
- Stars: 159
- Watchers: 4
- Forks: 21
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# opencv_dart
OpenCV Bindings for Dart Language. Support both asynchronous and synchronous!
| | | |
| :---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------: | :--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------: | :----------------------------------------------------------------------------------------------------------------------------------------------------: |
| | | |
| | | || Package | Link | Description |
| :---------------------------------------------------------------------------------------------------------------------------------------: | :-------------------------------------------------: | :-----------------------------------: |
| | [dartcv4](https://pub.dev/packages/dartcv4) | OpenCV bindings for Dart Language. |
| | [opencv_core](https://pub.dev/packages/opencv_core) | OpenCV for Flutter, without `videoio` |
| | [opencv_dart](https://pub.dev/packages/opencv_dart) | OpenCV for Flutter, with all modules |> [!NOTE]
> WIP, APIs may change in the future, contributions are welcome!- [opencv\_dart](#opencv_dart)
- [Demos](#demos)
- [Supported Platforms](#supported-platforms)
- [Status](#status)
- [Core Modules](#core-modules)
- [Contrib Modules](#contrib-modules)
- [Usage](#usage)
- [Pure Dart](#pure-dart)
- [Flutter](#flutter)
- [TODO](#todo)
- [Contributors](#contributors)
- [Acknowledgement](#acknowledgement)
- [Star History](#star-history)
- [License](#license)## Demos
| Screenshot | Link |
| :-------------------------------------------------------------------------------------------------------------------------------------------------------------: | :-----------------------------------------------------------------------------------------------------------: |
| | [example](packages/opencv_core/example/) |
| | [videoio texture renderer](https://github.com/rainyl/awesome-opencv_dart/tree/main/examples/texture_renderer) |
| | [DNN MNIST inference](https://github.com/rainyl/awesome-opencv_dart/tree/main/examples/dnn_mnist) |
| | [stitching](https://github.com/rainyl/awesome-opencv_dart/tree/main/examples/stitching) |## Supported Platforms
| Platform | Supported | Tested | Platforms |
| -------- | ------------------ | ------------------ | ------------------------------ |
| Android | :white_check_mark: | :white_check_mark: | x86_64, arm64-v8a, armeabi-v7a |
| iOS | :white_check_mark: | :white_check_mark: | arm64, x64(Simulator) |
| Linux | :white_check_mark: | :white_check_mark: | x64, arm64 |
| Windows | :white_check_mark: | :white_check_mark: | x64, arm64 |
| macOS | :white_check_mark: | :white_check_mark: | x64, arm64 |## Status
### Core Modules
| module | Binding status | Test status | description |
| ---------- | ----------------------- | ----------------------- | ----------------------- |
| core | :white_check_mark: | :white_check_mark: | Core module |
| calib3d | :white_check_mark: | :white_check_mark: | Calib3D module |
| dnn | :white_check_mark: | :white_check_mark: | DNN module |
| features2d | :white_check_mark: | :white_check_mark: | Features2D module |
| gapi | :x: | :x: | GAPI module |
| highgui | :white_check_mark: | :white_check_mark: | HighGUI module |
| imgcodecs | :white_check_mark: | :white_check_mark: | ImageCodecs module |
| imgproc | :white_check_mark: | :white_check_mark: | ImageProc module |
| ml | :x: | :x: | ML module |
| objdetect | :white_check_mark: | :white_check_mark: | Object Detection module |
| photo | :white_check_mark: | :white_check_mark: | Photo module |
| stitching | :ballot_box_with_check: | :ballot_box_with_check: | Stitching module |
| svd | :white_check_mark: | :white_check_mark: | SVD module |
| video | :white_check_mark: | :white_check_mark: | Video module |
| videoio | :white_check_mark: | :white_check_mark: | VideoIO module |### Contrib Modules
| module | Binding status | Test status | description |
| ------------- | ------------------ | ------------------ | -------------------- |
| aruco | :white_check_mark: | :white_check_mark: | ArUco module |
| img_hash | :white_check_mark: | :white_check_mark: | Image hashing module |
| cuda | :x: | :x: | |
| wechat_qrcode | :white_check_mark: | :white_check_mark: | |
| bgsegm | :x: | :x: | |
| superres | :x: | :x: | |
| xfeatures2d | :x: | :x: | |
| ximgproc | :white_check_mark: | :white_check_mark: | |
| xobjdetect | :white_check_mark: | :white_check_mark: | |
| xphoto | :x: | :x: | |
| quality | :white_check_mark: | :white_check_mark: | |- :x: : not finished
- :ballot_box_with_check: : partially supported
- :white_check_mark: : finished
- modules not in the above table are not considered, contributions are welcome
- ~~videoio: `cv.VideoCapture` from file is not supported yet~~ supported now.## Usage
### Pure Dart
```dart
import 'package:dartcv4/dartcv.dart' as cv;void main() {
final img = cv.imread("test/images/lenna.png", flags: cv.IMREAD_COLOR);
final gray = cv.cvtColor(img, cv.COLOR_BGR2GRAY);
print("${img.rows}, ${img.cols}");cv.imwrite("test_cvtcolor.png", gray);
}
```### Flutter
see [awesome-opencv_dart](https://github.com/rainyl/awesome-opencv_dart) and share yours
## TODO
- [x] ~~compile libs for android, linux~~
- [x] ~~support for iOS, macOS~~
- [x] ~~add more examples~~
- [ ] documentation
- [x] ~~modify C wrapper to catch exceptions~~
- [x] Native Assets, see `native-assets` branch
- [x] async
- [x] more/full test coverage
- [x] ~~directly include opencv source code, refactor cmakelists.txt~~## Contributors
rainy liu
Abdelaziz Mahdy
爱因斯唐
Gold87
JinWoo Jung
Escaton615
mdeleau
Matteo T.
## Acknowledgement
- `gocv` project: License: Apache-2.0
## Star History
[![Star History Chart](https://api.star-history.com/svg?repos=rainyl/opencv_dart&type=Date)](https://star-history.com/#rainyl/opencv_dart&Date)
## License
Apache-2.0 License