alangpierce / compgeomdemo Goto Github PK
View Code? Open in Web Editor NEWDemonstrates an algorithm that splits a colored Delaunay triangulation.
Demonstrates an algorithm that splits a colored Delaunay triangulation.
There are a few ways to approach this issue. One way is to have the entire original triangulation in the "background" in gray, up until the end.
Another potential idea is to only have the original triangulation for just this recursive call. So, the background builds at each step when we build up the
Another idea is to only show the original points, since we don't really need the original edges anymore (and the algorithm doesn't use those edges, or even have access to them).
Regardless of which one is done, a potentially nice-looking way to do this is to have each point slowly fade in as the red and blue triangulations are built. More specifically, a point that is in the triangulation might have opacity 1, while a point that is not in the triangulation might have an opacity between 0 (or some small value) and .5, where .5 means that it is the next point to be added, and 0 means that it is the last point to be added.
The two selected points at the start of the algorithm should be selected by a bold circle instead of a thin one, and the found point should be a different color so that there's an obvious distinction.
Currently you need to press space over and over to get out of the computation. There should really be some button to go back to the point insert mode, preferably with the original set of points intact (in case you accidentally start the computation before you meant to).
A big part of the cleverness of the algorithm is that some steps run in constant time for nontrivial reasons. Each step like this should have at least some explanation for why the running time is constant.
Currently, it's possible to create points where the text is, which looks bad. There should be a division near the bottom, and points should not be allowed to be placed in the "info/UI" area.
The step of the algorithm that places the vertex back into the triangulation isn't fully explained.
A good explanation would go as follows:
The point, disconnected from the graph, is added back in, and it and the previous nearest neighbor are highlighted. The triangles adjacent to the nearest neighbor are then highlighted in clockwise order starting from an arbitrary point until the one containing the newly added point is highlighted. The new edges are then added and we move to step 6.
It's sometimes annoying to have to press space over and over to step the algorithm. A nice feature would be to have it step automatically at a fixed rate (e.g. once a second).
The feature should probably be toggled with a check box. It may also be good to be able to set the step frequency.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.