Freestyle integration into Blender

August 28, 2011

Development updates on August 28

Filed under: Update — The dev team @ 10:19 PM

Since the last blog post, several functionality improvements were made in the Freestyle branch as reported below.

Stroke geometry modifiers

A new set of line style options for modifying stroke geometry was introduced in the Parameter Editor mode.  Stroke geometry refers to the backbone polyline of a stroke.  Now stroke geometry can be modified by a list of stroke geometry modifiers specified in the Geometry tab (previously referred to as Distort).  At the moment the following geometry modifiers are available, each with a set of animateable parameters:

  • Sampling: Changes the resolution of stroke backbone polylines.
  • Bezier Curve: Replace stroke backbone with a Bezier approximation of the stroke backbone.
  • Sinus Displacement: Add sinus displacement to stroke backbone.
  • Spatial Noise: Add spatial noise to stroke backbone.
  • Perlin Noise 1D: Add one-dimensional Perlin noise to stroke backbone.
  • Perlin Noise 2D: Add two-dimensional Perlin noise to stroke backbone.
  • Backbone Stretcher: Stretch the beginning and the end of stroke backbone.
  • Tip Remover: Remove a piece of stroke at the beginning and the end of stroke backbone.

Note to branch users: When you have a .blend file with Freestyle options specified, you need to add a Sampling modifier with the Sampling parameter value set to 5, which is the default polyline resolution previously used for line drawing in Freestyle.  Before geometry modifiers were introduced, this initial sampling was automatically done.  Now the initial sampling is a tunable parameter that can be omitted, allowing better control on polyline resolution.  If no sampling modifier is specified, your line drawing will result in coarse polylines.

Images below are a few example renders made with the following stroke geometry modifiers used: (a) no geometry modifiers, showing baseline stroke backbones; (b) Bezier Curve modifier; (c) Sinus Displacement modifier; (d) Backbone Stretcher and Spatial Noise modifiers.



Fill Range by Selection

A new push button Fill Range by Selection was added to the Distance from Camera and Distance from Object modifiers (see figures below).  This button allows you to automatically fill the Range Min and Max entries based on selected mesh objects.  For the Distance from Camera modifier, the Range Min (Max) entry is filled with the minimum (maximum) distance between the active camera and the vertices of selected mesh objects.  For the Distance from Object modifier, the distance between the target object and the mesh vertices is measured.


Stroke splitting at material boundary

A new toggle button for splitting strokes at material boundary was added to the Strokes tab.  This option divides strokes into pieces at material boundary.  The following renders illustrate the effect of the splitting option: (a) disabling the option results in a smooth (blurred) transition of stroke colors across material boundary; (b) enabling the option permits a flat color transition at material boundary.



August 1, 2011

Development updates on July 31

Filed under: Update — The dev team @ 1:07 AM

It has been a while since the last development updates.  This absence of branch activities was mainly because of time constraints the main dev (T.K.) had during the last few months.  Due to restricted time resources, commits to the branch were mostly limited to merges of changes from the trunk and bug fixes based on problem reports from branch users.  The issues addressed include: (1) a wrong use of matrix inversion in the Distance from Object modifier; (2) composite node parameter animation not working with Freestyle; (3) a memory leak in silhouette edge detection; (4) linker errors for building blenderplayer; and (5) a bug in line caps due to zero-length strokes.  The dev team appreciate the feedback from the branch users who kindly reported these issues, some with .blend files to help us reproduce the problems.

In addition, the Parameter Editor mode of the Freestyle graphical user interface was enhanced with new Material modifiers that allow you to change the line color, alpha transparency, and line thickness of strokes by object materials.  The screenshot below shows the GUI controls of the Material color modifier.

The following set of rendering results demonstrates a typical use the Material color modifier: (a) the stroke color is constant (i.e., the base color is black); (b) the Material color modifier is applied and the base color is replaced by the the diffuse color of object materials (i.e., blend = Mix, influence = 1.0); (c) same as (b) but the diffuse color of object materials is blended into the base color (blend = Add and influence = 0.4).


Artwork with Freestyle for Blender

In the meantime, several branch users released excellent animation shorts and movie clips made partly with Freestyle.  First, Chris Burton and his colleagues released a finished animation short “The Light at the End“.  This is one of the most impressive pieces of artwork that give you a real sense of how line drawing with Freestyle looks like.

Dolf Veenvliet (macouno) has been using Freestyle for his Entoforms project.  Entoforms are little creatures generated by a program that “grows” them through a kind of DNA strings.  The use of Freestyle is meant to give a “drawn” look to 3D renders according to one of project blog posts.

And last but not least, Ike AhLoe released a finished animation short “Clocked In“.  During the production of this artwork, he contributed to the Freestyle integration project through a number of bug reports and development updates.

We are very grateful for the authors of these art products, since the early adoption of the Freestyle renderer should have been tough and time-consuming due to bugs and limitations.  We hope these frontier examples encourage further use of Freestyle in future 3D art projects.

Create a free website or blog at