Suppose you wanted to use WPF 3D to create a dodecahedron. A regular dodecahedron has 12 faces, each of which is a pentagon. A handy source of the three-dimensional coordinates is this Wikipedia article . One easy approach is to break each pentagonal face into five triangles that meet at the center. Implementing it, you might come up with something like this XAML file from Chapter 3 of my new book 3D Programming for Windows : RotatingDodecahedron.xaml There's nothing really wrong about doing it this way. In fact, you can even define a TextureCoordinates collection and apply a non-solid brush, as in this XAML file from Chapter 5: RotatingDodecahedronWithRadialBrush.xaml However, if you wanted to shine a PointLight or a SpotLight on this figure, you're in bad shape. The illumination of a triangle from a PointLight or SpotLight is based on an interpolation over the surface of the triangle governed by the illumination at the vertices. To get it to work right, those triangles defining the surface
Read More...