OverviewFor my project I wrote a subdivision surface editor. My base project was to implement midpoint subdivision. For extras I implemented 4 other subdivision algorithms, as well as the ability to drag control points and triangulate a surface. Triangulation is done by taking all faces with n > 3 vertices and connecting each vertex to the centroid of the face, thus creating n new triangles.Surfaces are loaded from and saved to S3D files. Additionally, Bezier patch files can be loaded as triangular meshes. Surfaces can be subdivided using any combination of the subdivision schemes. Surface points can be moved around in the current X-Y viewplane by holding control and mouse-dragging a point, and can be moved along the Z axis by holding control and middle-mouse-dragging. A simple cube illustrates the subdivision schemes nicely. This is the original cube model and its triangulation in yellow: ![]() Here is the cube after 3 levels of each subdivision scheme:
Subdivision Schemes
ExamplesLooking at a triangular approximation to a torus, we can see that Loop subdivision produces the smoothest surfaces. Here is the original model and its complexity:![]() Here is the surface after 3 subdivisions of each scheme:
An interesting note on midpoint subdivision - subdividing a cube once with Doo-Sabin subdivision or twice with midpoint subdivision gives the same surface, which suggests that midpoint subdivision is much poorer:
My program can also handle very complex surfaces: ![]() |