13
$\begingroup$

I'd like to combine these features:

  1. The pixelated look of a wire material with anti-aliasing disabled.
  2. Proper occlusion of hidden lines.

A wireframe material produces the first feature, freestyle produces the second. Can a line set be created that produces neither double pixels nor gaps? Line thickness alone does not seem to be the answer.

There is the trick with two materials and z-offset, but I have trouble getting a really clean solution at the outline of the object. So a freestyle solution would be best.

enter image description here

The main problem is that freestyle (to the right) produces double pixels:

enter image description here

$\endgroup$
3
  • $\begingroup$ How about rendering the wire, then using an image editor to remove antialiasing? $\endgroup$
    – CharlesL
    Commented Aug 13, 2013 at 19:55
  • $\begingroup$ @CharlesL Why not just disable antialiasing in Render settings > anti-aliasing? $\endgroup$
    – gandalf3
    Commented Aug 13, 2013 at 19:58
  • $\begingroup$ I added a second picture to clarify my problem. $\endgroup$ Commented Aug 13, 2013 at 20:54

2 Answers 2

6
$\begingroup$

You can use the Blender OpenGL viewport rendering for this.

  • Go to edit mode, activate edge-select and Z-Clipping:

viewport settings

  • Go to User Preferences, System, then disable all lights and make the final one black (color and specular, in my screenshot, only the specular ones are set to black).

light settings

  • Go to the Theme settings, 3D View and set selected edges to white and selected faces to black.

theme settings

  • Select everything and press the "OpenGL render active viewport" (3D view header, the left one in the screenshot).

viewport render

To remove other lines such as lamps you can enable Only render in 3D view > Properties panel (N) > Display > Only render and press CtrlSpace to toggle the 3D manipulator.

If the background is a problem, you can put a face there or also make it black in the theme settings.

AA has to be disabled, otherwise you will get smooth lines.

Result:
Result

$\endgroup$
6
  • 2
    $\begingroup$ Crazy, but close enough. Although I'd suggest turning wireframe on in the object's drawing options, so several objects are possible. Enabling all edges helps as well. Great Trick $\endgroup$ Commented Aug 13, 2013 at 21:04
  • 1
    $\begingroup$ That's possible, but keep in mind that turning Wire on in the object's drawing options will hide edges on flat surfaces, so you don't really get a full wire. $\endgroup$
    – JulianHzg
    Commented Aug 14, 2013 at 5:51
  • 2
    $\begingroup$ That's what 'draw all edges' in the object's display panel is for. $\endgroup$ Commented Aug 14, 2013 at 5:55
  • $\begingroup$ Ah, forgot that existed. Very good. $\endgroup$
    – JulianHzg
    Commented Aug 14, 2013 at 6:06
  • 2
    $\begingroup$ Alternatively your could just set the Horizon Color to white, use a white shadeless material, change viewport shading to Texture and invert the image in the compositor. $\endgroup$
    – Aldrik
    Commented Aug 14, 2013 at 10:19
3
$\begingroup$

You can get this with a wireframe material using this method (see this):

  1. Disable anti-aliasing in render settings

    enter image description here

  2. Create a material wire material, enable transparency and increase the Z offset:

    enter image description here enter image description here

  3. Create another material for your object and make it pure black:

    enter image description here

  4. Assign the second (black) material to all the faces (Tab> edit mode A> select all > Assign.

  5. Set the world color to black:

    enter image description here

  6. Render:

    enter image description here enter image description here

Note that sometimes with low resolution renders you may have to increase the Z offset even more to prevent gaps in the edges.

$\endgroup$
3
  • $\begingroup$ your render exactly outlines my problem. you have a lot of double pixels there. Adjusting line thickness isn't the answer. I do know the freestyle basics. Sorry if I haven't made myself clear enough, although I mentioned double pixels. $\endgroup$ Commented Aug 13, 2013 at 20:37
  • $\begingroup$ @Haunt_House Oops, sorry. I don't know how I missed that :P $\endgroup$
    – gandalf3
    Commented Aug 13, 2013 at 21:07
  • $\begingroup$ I have to apologize. Hm, the editing is sometimes scary. Although the question is now more technically correct, there was a reason I used the phrase 'perfect wireframe'. Not very precise, I admit. But that's what the body is for. $\endgroup$ Commented Aug 13, 2013 at 21:13

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .