Skip to content

Commit

Permalink
Fixed BC update
Browse files Browse the repository at this point in the history
  • Loading branch information
zfergus committed Sep 22, 2021
1 parent 8c6f0fd commit ab11908
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 2 additions & 2 deletions cmake/PolyfemPythonDownloadExternal.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ endfunction()
function(polyfem_python_download_polyfem)
polyfem_python_download_project(polyfem
GIT_REPOSITORY https://github.com/polyfem/polyfem.git
GIT_TAG c49e22ebef589acb23a69285f420b5b1c8305449
GIT_TAG 75298361e234570cb8fee2df21438ccb6b826a4f
)
endfunction()

Expand All @@ -52,4 +52,4 @@ function(polyfem_python_download_data)
GIT_REPOSITORY https://github.com/polyfem/polyfem-data.git
GIT_TAG 09ba9e7db4c1a87cdd16f53e0bf54e19d599a465
)
endfunction()
endfunction()
6 changes: 4 additions & 2 deletions src/binding.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
#include <polyfem/MeshUtils.hpp>
#include <polyfem/GenericProblem.hpp>
#include <polyfem/StringUtils.hpp>
#include <polyfem/ALNLProblem.hpp>

#include "raster.hpp"

Expand Down Expand Up @@ -494,6 +495,7 @@ PYBIND11_MODULE(polyfempy, m)
// std::cout << s.step_data.rhs_assembler->problem_->is_rhs_zero() << std::endl;
// std::cout << s.step_data.nl_problem->rhs_assembler.problem_->is_rhs_zero() << std::endl;
json solver_info;
s.step_data.alnl_problem->update_target(t);
s.solve_transient_tensor_non_linear_step(t0, dt, t, solver_info);
return solver_info;
},
Expand Down Expand Up @@ -873,7 +875,7 @@ PYBIND11_MODULE(polyfempy, m)
}
}

return rendering_lambda(tmp, self.boundary_triangles, width, height, camera_positionm, camera_fov, camera_near, camera_far, is_perspective, lookatm, upm, ambient_lightm, lights, diffuse_colorm, specular_colorm, specular_exponent);
return rendering_lambda(tmp, self.boundary_triangles, width, height, camera_positionm, camera_fov, camera_near, camera_far, is_perspective, lookatm, upm, ambient_lightm, lights, diffuse_colorm, specular_colorm, specular_exponent);
},
"renders the scene", py::kw_only(), py::arg("width"), py::arg("height"), py::arg("camera_position") = Eigen::MatrixXd(), py::arg("camera_fov") = double(0.8), py::arg("camera_near") = double(1), py::arg("camera_far") = double(10), py::arg("is_perspective") = bool(true), py::arg("lookat") = Eigen::MatrixXd(), py::arg("up") = Eigen::MatrixXd(), py::arg("ambient_light") = Eigen::MatrixXd(), py::arg("lights") = std::vector<std::pair<Eigen::MatrixXd, Eigen::MatrixXd>>(), py::arg("diffuse_color") = Eigen::MatrixXd(), py::arg("specular_color") = Eigen::MatrixXd(), py::arg("specular_exponent") = double(1))
.def(
Expand All @@ -894,7 +896,7 @@ PYBIND11_MODULE(polyfempy, m)
v_count += vf_pair.first.rows();
f_count += vf_pair.second.rows();
}
return rendering_lambda(vertices, faces, width, height, camera_positionm, camera_fov, camera_near, camera_far, is_perspective, lookatm, upm, ambient_lightm, lights, diffuse_colorm, specular_colorm, specular_exponent);
return rendering_lambda(vertices, faces, width, height, camera_positionm, camera_fov, camera_near, camera_far, is_perspective, lookatm, upm, ambient_lightm, lights, diffuse_colorm, specular_colorm, specular_exponent);
},
"renders the extrinsic scene", py::kw_only(), py::arg("vertex_face") = std::vector<std::pair<Eigen::MatrixXd, Eigen::MatrixXi>>(), py::arg("width"), py::arg("height"), py::arg("camera_position") = Eigen::MatrixXd(), py::arg("camera_fov") = double(0.8), py::arg("camera_near") = double(1), py::arg("camera_far") = double(10), py::arg("is_perspective") = bool(true), py::arg("lookat") = Eigen::MatrixXd(), py::arg("up") = Eigen::MatrixXd(), py::arg("ambient_light") = Eigen::MatrixXd(), py::arg("lights") = std::vector<std::pair<Eigen::MatrixXd, Eigen::MatrixXd>>(), py::arg("diffuse_color") = Eigen::MatrixXd(), py::arg("specular_color") = Eigen::MatrixXd(), py::arg("specular_exponent") = double(1));

Expand Down

0 comments on commit ab11908

Please sign in to comment.