I have a schematic of a raspberry pi that is completely flat, no solid faces, just connected vertices.
Is it possible to render these lines somehow, so that it looks like a 2D drawing?
Maybe with freestyle?
Blender Stack Exchange is a question and answer site for people who use Blender to create 3D graphics, animations, or games. It only takes a minute to sign up.Sign up to join this community
Note: This answer is for 2.79 only. For 2.8+ you will have to look at some of the other answers.
The simplest way to render an object that has no faces is to change the material type in the internal renderer to a 'Wire' material:
The mesh on the left, when rendered, looks like the image on the right:
I also changed it to be 'Shadeless' in the shading panel of the material so that it wouldn't be affected by shadows and would be lit equally.
For the sake of completeness, there is also the possibility to use the skin modifier. It removes faces (if present) from your mesh and builds tubes intersecting at all vertices.
Below a screenshow showing original mesh (manually deleted faces), with skin modifier and last with skin modifier and subdivision modifier.
You can scale the tubing thickness at each vertices (use ctrl+A in edit mode).
It seems as if freestyle doesn't care for wireframe meshes. Even faces aren't recognized if they have 0 surface area (edge extruded and escaped).
If you want to achieve that effect with freestyle then assign a material to your mesh (with faces) that has Z Transparency enabled. Alpha and Specularity should be set to 0.0.
To make the flat edgelines visible for freestyle, just extrude them all away from the camera. Then select the edges that you want to keep seeing with a Border Select and hit CtrlE - Mark Freestyle Edge. Set freestyle to render nothing but Edge Mark. The transparent material will hide the surplus geometry.
Alternatively you can set the material to Cast Only in the Shadow panel. It works if your scene doesn't have shadows.
Or you can disable Solid in the Layer panel of the Render Layers. Then nothing gets rendered except the freestyle pass. I get the best results if I disable Chaining and set the Caps to Round in the Freestyle Line Style panel.
The advantages: You don't have to display every edge. You can control line thickness and line style very creatively. Dashed lines are possible, to name just one option.
(presumably also valid for 2.8 versions)
A simple way is to convert the mesh into curves, then bevel it, what gives the resulting "wire" a solid appearance. In Object mode:
The resulting object can be rendered in any way using the material of your choice.
Pretty easy and fast way.
If you really need flat lines to be rendered, I suggest to rather not using curves. Instead, in Object mode apply the Skin Modifier as suggested above by Gunslinger. This way is a bit more complicated in order to achive "flat" lines similar to a 2D drawing. Because the resulting skin first appears like a bold tube. But this can be changed in Edit mode:
However, this method seems to be computationally demanding for big meshes with lots of edges (compared to the other method) so that it may be slow when it comes to rendering.
In blender 2.8+ :
If you have an edge only mesh like for instance :
Disable all the overlays but the edges :
Setup your animation keyframes :
Resize and frame your viewport as it was a camera :
Set your output as if it was a regular render :
Render the animation with View > Viewport Render Animation :