I have been following the MSDN documentation on how to render a model with a basic effect.
Which is neat. I can change the rendering to display in wireframe by adding the following line to the example code, before the DrawModel method’s double loop:
GraphicsDevice.RasterizerState = WIREFRAME_RASTERIZER_STATE;
Where I’ve initialized WIREFRAME_RASTERIZER_STATE in the constructor as
RasterizerState WIREFRAME_RASTERIZER_STATE = new RasterizerState() { CullMode = CullMode.None, FillMode = FillMode.WireFrame };
Is there an equally easy addition/modification I can make to display just the vertices in the imported model? From my understanding, Wireframe mode tells XNA to render lines instead of triangles, but unfortunately the RasterizerState method that I used above doesn’t have a fill mode that displays just the vertices (it’s SOLID or WIREFRAME).
Given that most of the draw functionality is hidden in the MSDN example, I was hoping someone could direct me as to how to simply render the points without connecting them.
FillMode.Pointwas removed in XNA 4.0. This blog post describes why, and provides work-arounds.In your situation you will probably find that you have to process the model data to generate actual triangles to render in place of points.