Comments (3)
Hello!
You can use
MeshLib/source/MRMesh/MRMesh.h
Lines 59 to 60 in 47bb12e
this function to extact points coordinates, also if you need to cut mesh in this path you should use
cutMesh
functionality:MeshLib/source/MRMesh/MRContoursCut.h
Lines 77 to 99 in 47bb12e
MeshLib/source/MRMesh/MRContoursCut.h
Lines 149 to 165 in 47bb12e
from meshlib.
Hello! You can use
MeshLib/source/MRMesh/MRSurfacePath.h
Lines 50 to 54 in ed5add2
this function (or other functions in this file) to find the path.
from meshlib.
After finding the required point, then use the SplitDge algorithm to find that the output results can not be visualized.
code**************************
auto cylinder = MR::MeshLoad::fromAnyStl("D:/code/meshlib221/chamfer/model/Subtraction.stl");
MR::MeshTriPoint a = MR::getVertexAsMeshTriPoint(cylinder->topology, MR::EdgeId(70), MR::VertId(21));
MR::MeshTriPoint b = MR::getVertexAsMeshTriPoint(cylinder->topology, MR::EdgeId(166), MR::VertId(24));
MR::GeodesicPathApprox Approx = MR::GeodesicPathApprox::DijkstraAStar;
auto geodesicpath = MR::computeGeodesicPath(*cylinder, a, b,Approx);
for (auto result : *geodesicpath)
{
MR::EdgeId edge = MR::EdgeId(result.e);
MR::VertId vertA = cylinder->topology.org(edge);
MR::VertId vertB = cylinder->topology.org(edge.sym());
MR::Vector3f pointA = cylinder->points[vertA];
MR::Vector3f pointB = cylinder->points[vertB];
MR::Vector3f point = point + (pointB - pointA) * result.a;
cylinder->splitEdge(edge, point);
}
cylinder->invalidateCaches();
code**************************
Do I need to update each splitEdge?
from meshlib.
Related Issues (20)
- line self-intersection HOT 2
- Local setup HOT 5
- Error while showing numpad keys in F1 menu
- Negative offsetting in offsetMesh HOT 1
- Negative offset in thickenMesh results in incorrect filling of mesh HOT 3
- Readme installation steps are incorrect for Linux HOT 4
- Installation on Linux when sudo privileges are not available HOT 1
- Python Meshlib DistanceMap Interpolation Issue HOT 2
- meshlib.mrmeshpy.uniteCloseVertices does not exist in Python HOT 4
- Plane cut HOT 2
- Minkowski Sum in python HOT 2
- Problems in refine in cylinder mesh HOT 1
- add possibility to support rectangular planes
- setup z scale as ( ScaleX + ScaleY ) / 2 for plane feature HOT 1
- Creating grid meshes based on arbitrary shape input HOT 29
- Create a 3D Mesh from a list of vertices and faces. HOT 3
- Hole & Boundary edge length in Python HOT 5
- The Angle between two vectors is 0 to pi, why not 0-2pi HOT 4
- ImportError: libpython3.11.so.1.0: cannot open shared object file: No such file or directory HOT 1
- Are there any examples of emscripten for reference? 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 meshlib.