This project was aimed at developing a dynamic link library for the room modelling system named Ambiente designed by CCP Development GmbH. This DLL enables subtracting one three-dimensional object from another and is widely used in the Ambiente room modelling system, in particular for cutting window and door openings.
This small but complex routine calculates the result of intersection of two input objects, positive and negative ones, and returns the remaining parts of the positive object without the intersection area as a single 3D object.
All objects are presented as sets of polygons. The resulting object is returned in the same format as the input objects.
Using this function, it is possible to process very complex objects. The program has been tested on objects that have tens of thousands of surfaces. Combining several function calls, it is possible to subtract one set of objects from another.
The complexity of the program consists in its ability to round off errors in coordinates.