Skip to content

Commit

Permalink
Merge pull request #300 from abdelaziz-mahdy/fix-make-file
Browse files Browse the repository at this point in the history
make file auto clone
  • Loading branch information
rainyl authored Nov 28, 2024
2 parents 0f1f788 + bc98fd4 commit 618d4c3
Show file tree
Hide file tree
Showing 5 changed files with 72 additions and 8 deletions.
15 changes: 12 additions & 3 deletions packages/dartcv/Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
.PHONY: ffigen ffigen_test
.PHONY: ffigen ffigen_test clone_repo clean_repo

ffigen:

ffigen: clone_repo
dart run ffigen --config ffigen/ffigen_const.yaml
dart run ffigen --config ffigen/ffigen_types.yaml
dart run ffigen --config ffigen/ffigen_core.yaml
Expand All @@ -18,6 +19,14 @@ ffigen:
dart run ffigen --config ffigen/ffigen_video.yaml
dart run ffigen --config ffigen/ffigen_videoio.yaml

ffigen_test:

clone_repo:
echo "Getting submodules"
@git submodule update --init --recursive

echo "Updating submodules"
@git submodule update --remote

ffigen_test: clone_repo
dart run ffigen --config ffigen/ffigen_types.yaml
dart run ffigen --config ffigen/ffigen_core.yaml
8 changes: 4 additions & 4 deletions packages/dartcv/lib/src/g/core.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -628,12 +628,12 @@ files:
name: registerErrorCallback
c:@F@setLogLevel:
name: setLogLevel
c:@T@double_t:
name: double_t
c:@T@float_t:
name: float_t
c:exception.h@T@ErrorCallback:
name: ErrorCallback
c:math.h@T@double_t:
name: double_t
c:math.h@T@float_t:
name: float_t
c:types.h@T@CvPoint:
name: CvPoint
c:types.h@T@CvRect:
Expand Down
51 changes: 51 additions & 0 deletions packages/dartcv/lib/src/g/imgproc.g.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2714,6 +2714,43 @@ class CvNativeImgproc {
ffi.Pointer<CvStatus> Function(
Mat, Mat, Mat, Mat, int, int, imp1.CvCallback_0)>();

ffi.Pointer<CvStatus> cv_intersectConvexConvex(
VecPoint p1,
VecPoint p2,
ffi.Pointer<VecPoint> p12,
bool handleNested,
ffi.Pointer<ffi.Float> rval,
imp1.CvCallback_0 callback,
) {
return _cv_intersectConvexConvex(
p1,
p2,
p12,
handleNested,
rval,
callback,
);
}

late final _cv_intersectConvexConvexPtr = _lookup<
ffi.NativeFunction<
ffi.Pointer<CvStatus> Function(
VecPoint,
VecPoint,
ffi.Pointer<VecPoint>,
ffi.Bool,
ffi.Pointer<ffi.Float>,
imp1.CvCallback_0)>>('cv_intersectConvexConvex');
late final _cv_intersectConvexConvex =
_cv_intersectConvexConvexPtr.asFunction<
ffi.Pointer<CvStatus> Function(
VecPoint,
VecPoint,
ffi.Pointer<VecPoint>,
bool,
ffi.Pointer<ffi.Float>,
imp1.CvCallback_0)>();

ffi.Pointer<CvStatus> cv_invertAffineTransform(
Mat src,
Mat dst,
Expand All @@ -2734,6 +2771,20 @@ class CvNativeImgproc {
_cv_invertAffineTransformPtr.asFunction<
ffi.Pointer<CvStatus> Function(Mat, Mat, imp1.CvCallback_0)>();

bool cv_isContourConvex(
VecPoint contour,
) {
return _cv_isContourConvex(
contour,
);
}

late final _cv_isContourConvexPtr =
_lookup<ffi.NativeFunction<ffi.Bool Function(VecPoint)>>(
'cv_isContourConvex');
late final _cv_isContourConvex =
_cv_isContourConvexPtr.asFunction<bool Function(VecPoint)>();

ffi.Pointer<CvStatus> cv_line(
Mat img,
CvPoint pt1,
Expand Down
4 changes: 4 additions & 0 deletions packages/dartcv/lib/src/g/imgproc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -206,8 +206,12 @@ files:
name: cv_grabCut
c:@F@cv_integral:
name: cv_integral
c:@F@cv_intersectConvexConvex:
name: cv_intersectConvexConvex
c:@F@cv_invertAffineTransform:
name: cv_invertAffineTransform
c:@F@cv_isContourConvex:
name: cv_isContourConvex
c:@F@cv_line:
name: cv_line
c:@F@cv_linearPolar:
Expand Down

0 comments on commit 618d4c3

Please sign in to comment.