Category Archives: Fade Best Practices

Boolean Operations on Polygons with Holes

Boolean operations on polygons with holes Source code that computes the union, difference or intersection of polygons with Fade2D is often requested. Therefore, C++ example code that computes the union of polygons is provided here: The algorithm handles arbitrary shapes (convex/non-convex, with or without holes) and it is numerically robust. Download example code here and […]

Read More

Remove Border Triangles

How To Remove Badly Shaped Border Triangles A Delaunay triangulation is convex but that does not always hold for your data. As a consequence your triangulation may contain triangles close to the convex hull that do not really belong to the desired non-convex result. This post shows how to remove them. Minimal Example in C++ […]

Read More

Random Polygons, Surfaces, Segments for Automated Software Tests

Geometry programming: Degenerate cases, numeric issues and unexpected geometric settings make a developer’s life hard. Automated software stress tests with random data are essential to discover bugs early. But creating random polygons without self-intersections or even random surfaces is for example not trivial. For convenient debugging the module testDataGenerators provides repeatable Random surfaces Random polygons […]

Read More

Runtime for a Face List

Storing a triangulation as a list consisting of three indices per triangle is a common task and leads to a frequently asked question that reads as follows: “Creating a triangulation with Fade is fast. But when I store a face list of vertex indices it runs forever. What is wrong?”. The basic answer: It is […]

Read More

Progress Bar Mechanism

Fade is very fast and most of the time you won’t need a progress bar. But for huge operations you may want to connect your progress bar to Fade’s progress update mechanism. Step 1: Create your own class Create some custom class that derives from MsgBase so that it can receive messages from Fade. The […]

Read More

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.