Basic ‘visible edges solid, hidden edges dashed’ Freestyle rendering in Blender
 Here’s a mini-tut sharing my experience with figuring out how to render Freestyle in Blender scenes, in this specific diagram/technical/architecture-friendly style where visible edges are shown with solid lines, and hidden edges are shown with dashed lines.
It is actually quite simple..Once you figure out how to get freestyle going (Tick Freestyle in the Render tab), and edit linesets/styles (go to the next tab, RenderLayers, Scroll down and unfold both Freestyle and Freestyle Line Set):
You start with one lineset, which you can use to render the visible edges.
Add a second lineset, which selects Hidden edges rather than Visible (in Visibility section), and enable Dashed line option (at the bottom), setting the first two numbers to 4, 4 (representing a 4px on, 4px off dash pattern).
You might also want to make sure that the base thickness of your dashed lineset is less than the main lineset (check the Thickness tab). I chose 3 for my dashed lines and 5 for my main lines.
Finally, according to the scale of the diagram, you might want Blender to reduce line opacity or size according to distance from the camera.
You can do that by adding a 'distance from camera' modifier in the Alpha tab. In my test document, I used Subtract mode with 0.5 influence, and then selected the all the objects I wanted and hit 'fill range by selection'.
I did that for both the main line style and dashed line style.
The result of the above looks like this:
And here is a version using a toon material, since that is more typical:
PS. I later decided that the dashed line fading wasn’t noticable enough, and switched to a Distance from Object modifier instead, with the object being the closest sphere. For ultimate control, I guess you would use Distance from Object with an empty designed exclusively to control line fading.











