4

I am looking for a render engine capable of rendering vectors, i.e. vertices, edges, curves, etc -- objects that have no volume & no faces.

I'd also like the render engine to be free.

Below is an example what I am trying to accomplish. See how there are only points and lines in the image? That's the style I'm wanting to achieve.

I am also hoping the render engine can make much nicer pictures than this (higher resolution, control over materials, transparency, etc), and also to make animations.

Given these constraints, are there any vector render engines that stand out as good solutions?

enter image description here

gandalf3
  • 157,169
  • 58
  • 601
  • 1,133
mKurowsKi
  • 43
  • 1
  • 4

3 Answers3

7

Blender Internal

BI can render wireframes on edge only meshes, whether shaded or shadeless:

enter image description here

BI can also render halos, which work on vertex only meshes (there are a few in the middle of the above scene), but they are affected by distance.

OpenGL

However, you could try using the openGL preview render (using the same system that renders the viewport)

Unfortunately, options for coloring objects individually is rather limited using meshes without faces. You can tweak some things (e.g. vertex size) by editing the themes, but this is obviously not what it was designed for.

You can render animations and stills with openGL render by clicking the buttons in the header of the 3D view, or in the render menu in the Info panel (at the top of the window):

enter image description here

For example:

enter image description here

Original answer:


Freestyle can render a scene as svg, using either SVGwriter or this set of python scripts.

Note that freestyle requires faces to work.

gandalf3
  • 157,169
  • 58
  • 601
  • 1,133
  • Uh, where FreeStyle was when I needed it few years back to make pretty images for LaTeX documents? – elmo Apr 16 '14 at 15:41
  • gandalf3 - unless I've misunderstood, it seems that Freestyle could not render a point or line? – mKurowsKi Apr 16 '14 at 16:15
  • (since a point or line will not have faces) – mKurowsKi Apr 16 '14 at 16:37
  • @mKurowsKi It doesn't seem to support this, however depending on your mesh you may be able to add some faces with a modifier or something. Is it possible you could give an example of the kind of mesh you want to render? – gandalf3 Apr 16 '14 at 18:31
  • there is another exporter script for SVG mentioned in blenderartists: http://blenderartists.org/forum/showthread.php?282824-SVG-output-script It allows you to export the viewport's view as SVG –  Apr 16 '14 at 19:52
  • @gandalf3 - I am interested in using Blender to render representations, such as a point cloud with lines and surfaces that represent objects. I may want to render a scene that has no meshes at all, if I only have points and lines. I don't want to convert anything to volumes since points or lines that are farther away would not be visible. I'd like all points in a scene to have equal size. I can see points like this in the Blender "design windows", which use some kind of 3D graphics engine I thought might be renderable with some vector render engine? – mKurowsKi Apr 16 '14 at 20:08
  • @mKurowsKi the script mentioned will allow you to do that: http://dl.dropboxusercontent.com/u/16486113/Blender/archivos/temp/SVG/M6.svg –  Apr 16 '14 at 20:34
  • @mKurowsKi Sorry for my confusion.. In blender, vertices and edges (what I assume you are referring to with "points" and "lines") are still part of a mesh, even if it has no faces. It's also possible to have faces without a volume, e.g. a 2D plane. I made the assumption you wanted the output in a scalable vector format from "vector render engine", if I'm wrong I can think of a few was to render equally size points, but the output will be raster. Another workaround for freestyle might be to use "volume" meshes and a orthographic camera to make them appear the same size independent of distance. – gandalf3 Apr 16 '14 at 22:31
  • @gandalf3 - equally sorry on my end for the confusion. I am talking about points and lines that are independent of a mesh or faces. Perhaps my choice in wording for "vector render engine" is not the most suitable, but I meant it to emphasize any non-ray tracing render engine (i.e. volumetric render engine). I am not biased towards an SVG solution. Any solution that can render a point that is infinity small, or a line that is infinity thin to a certain size or width. I'm not sure what you mean by the output will be a raster? – mKurowsKi Apr 16 '14 at 22:35
  • @cegaton - I'm currently on a computer that is blocking any links to user dropbox content, I will try later today on another computer. – mKurowsKi Apr 16 '14 at 22:38
  • @mKurowsKi The output will be in pixels, not vector curves. – gandalf3 Apr 16 '14 at 22:53
  • @gandalf3 - thanks for your updated answer. OpenGL does do what I basically asked, and a raster final render product is what I'm after. It would be better if this solution also supported much more detailed control of point and line appearance (such as transparency), but this is definitely a start! – mKurowsKi Apr 17 '14 at 05:07
  • There is a patch which will allow per object color in wireframe view, though admittedly this solution is all rather hacky to begin with. – gandalf3 Apr 18 '14 at 07:40
2

Adding a Minimal Bevel to a Curve

If you are only wanting outlines, such as this:

enter image description here

then you can achieve this very easily with either Blender Render or Cycles Render Engines by using a very minimal bevel on a wireframe curve object. Here is how you can do this:

  1. Either create an object or import one.

  2. If any parts of your model are curves, then convert them to mesh:
    Select the curve objects -> ALTC -> Convert to Mesh

  3. Now delete all the faces from your mesh:

    • Select your mesh

    • Go into Edit mode (TAB)

    • Select All (A)

    • Delete faces only (X -> Faces Only)

    • Exit Edit mode (TAB)

    enter image description here

  4. Now select the remaining wireframe and convert it from a mesh object to a curve object:
    (ALTC -> Convert to Curve)

  5. Add a Circle Curve (SHIFTA -> Curve -> Circle)

  6. Select your wireframe and:

    • Add a bevel to it:
      Object Properties panel -> Curve tab -> Geometry section -> Set Bevel Object to the circle curve created in step 5

    • Scale down the circle curve until your wireframe is as thin as you want it to be:
      Select circle -> S + Drag mouse

    enter image description here

  7. Add a material to you model. If you like a flat look without any shadows, use an Emission Shader -- then you won't even have to worry about adding & adjusting lamps. To do this, select the model and then in the Object Properties window:
    Material tab -> Add new material -> Surface section -> Surface -> Emission

    enter image description here

When rendered, it will look like a wireframe:

enter image description here

If you render and feel the wireframe lines look too thick, scale the circle curve down some more. However, if the circle is already so small you don't see it in the 3D Viewport, select it in the Outliner:

enter image description here

Thom Blair III
  • 16,535
  • 20
  • 75
  • 112
  • How would you go about coloring the object? since a curve has no mass materials seem like they wouldn't work the same way. When plotting graphs and the such, color coding is almost always necessary – Konner Rasmussen Apr 16 '14 at 04:59
  • Once you put the bevel on the curve in step 6, the "lines" you see in the animation at the end of step 6 are actually VERY thin cylinders, so materials can be applied normally. I'll update my answer to show that. – Thom Blair III Apr 16 '14 at 05:07
  • Hi Thom - thanks for this detailed explanation, however, I'm looking to directly render a point or line (not part of a box or any other shape), without converting it so a volume. (Sorry, it seems that I did not use the correct Blender terminology - I've added an edit to the original question.) – mKurowsKi Apr 16 '14 at 16:21
  • How would I do this in blender with python (2.7)? – volvox Oct 06 '15 at 17:54
2

For completeness, its worth noting that there are systems to render vector data like this.

To name a few:

Writing an exporter for programs like this shouldn't be so hard (depending on exactly what you want to display).

ideasman42
  • 47,387
  • 10
  • 141
  • 223