Change In Python Example

I've tested that this change can make sense.
fixes-turtlebasket
Chen Yuda 2022-11-01 16:49:13 +08:00 committed by GitHub
parent ccd90cc811
commit 8cac752e6a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 5 deletions

View File

@ -8,9 +8,9 @@ PYBIND11_MODULE(opengjkc, m) {
[](Eigen::Array<double, Eigen::Dynamic, 3, Eigen::RowMajor> &arr1,
Eigen::Array<double, Eigen::Dynamic, 3, Eigen::RowMajor> &arr2)
-> double {
struct simplex s;
struct bd bd1;
struct bd bd2;
gkSimplex s;
gkPolytope bd1;
gkPolytope bd2;
bd1.numpoints = arr1.rows();
std::vector<double *> arr1_rows(arr1.rows());
for (int i = 0; i < arr1.rows(); ++i)
@ -23,8 +23,8 @@ PYBIND11_MODULE(opengjkc, m) {
arr2_rows[i] = arr2.row(i).data();
bd2.coord = arr2_rows.data();
double a = gjk(bd1, bd2, &s);
double a = compute_minimum_distance(bd1, bd2, &s);
return a;
});
}
}