Using Inkscape effects wisely

Slashdot it! Delicious Share on Facebook Tweet! Digg!
Luciano Lourenco, Free Art License, wiki.softwarelivre.org/InkscapeBrasil/Imagem108

Luciano Lourenco, Free Art License, wiki.softwarelivre.org/InkscapeBrasil/Imagem108

Inking It In

Besides basic drawing functions, Inkscape provides sophisticated effects that can transform vector lines into soft, flowing brushstrokes or automate the drawing of paper-fine lines.

Inkscape is known as a drawing program, because image elements in an Inkscape document depend on lines (called vectors ) and not colored pixels like you use in bitmap programs. Its sometime association with randomly scattered sketches doesn't do the program with all its many effects full justice.

In its current version 0.48, Inkscape [1] can create images that are more like hand-painted watercolors than pencil drawings. However, these images are still based solely on lossless, scalable vector shapes (Figure 1).

Figure 1: The Inkscape drawing looks like a bitmap, but it's based exclusively on resolution-independent and Inkscape curve-tool editable vector curves.

This article will deal primarily with basic shapes and Bézier curves, which use control points to form basic shapes. Their smooth transitions and intuitive handling make them the digital equivalent of the French curve tool used by draftsmen. Since my previous Inkscape article appeared in our sister publication Linux Magazine [2] in 2005, nothing much has changed from Inkscape's solid base.

Lens Adapters

From the outset, Inkscape was capable of drawing complex shapes. But, because the program makes use of simple color fills and gradients, its graphics have tended to look like cartoons. From Inkscape 0.45 (February 2007), however, so-called filters (from the Filters menu) have added more depth and a little pizzazz.

These filters act like true camera filters that are attached to lenses that distort and colorize the object. As in photography, many filters can be layered. The effects can be undone independently of the usual undo list, making experimentation a pleasure.

Inkscape 0.48 has about 220 such filters that divide the program into 18 fairly intuitively named categories (from the Filter Effects menu). Figures 2 through Figure 4 show three typical examples from each of the categories, showing more clearly what's hidden behind each filter name. The images shown are based on a photo, whereas other filters apply to vector objects.

Figure 2: The ABCs filter category collects the most basic effects; Protrusions attach themselves to edges; Textures cover the entire object; Non-Realistic 3D Shaders handle cartoon-like, non-realistic 3D effects; Overlays only partially overlay objects; and the Blurs category is self-explanatory.
Figure 3: The Ridges filter provides a 3D profile with edge enhancement; Distort effects distort the object; Materials change the form and surface texture to various materials; Bevels form beveled materials; Morphology emphasizes the image outline; and Image Effects include typical bitmap effects much like those in GIMP.
Figure 4: Bumps handle surface grain; Shadows and Glows provide glow and lighting effects; Scatter creates tiny fragments; the three groups on the right (Image Effects, Transparent; Color; and Transparency Utilities) are for bitmaps.

In principle, all filter effects can be applied to the bitmaps embedded in each image as well as to the usual drawing elements. Many, however, are especially conceived for bitmaps, and they all have a striking impact on vector elements with their many details and colors.

Despite their number and variety, the Inkscape filters don't come close visually to the Live Effects in Adobe's Illustrator. The market leadership is not easy to take away from the commercial maker and its expensive program. A major limitation of Inkscape's effects lies in their missing settings. Filter dialogs often don't let you control the overall strength of the effect.

Primitivism

As a kind of compensation for the lack of settings, Filters | Filter Editor provides an editor that exposes the basic SVG filters individually that become the common filters applied to objects (Table 1). Figure 5 shows the basic components ("filter primitives") of the Bumps | Tinfoil preset filter. The first primitive is Gaussian blur (call-out 1 in the figure) that you can control with horizontal and vertical sliders at the bottom (call-out 2).

Figure 5: The Filter Editor, with which you can control the SVG base filters for effects, lets you fine-tune the filter after it's applied or create new effects.

Table 1

Base Effects in Inkscape

Specular Lighting Spotlighting (pseudo-3D)
Image Renders external graphics
Diffuse Lighting Background lighting (pseudo-3D)
Color Matrix Matrix-based color transformation
Flood Single Color background, mostly used with Composite
Gaussian Blur Standard blur filter
Composite Overlapping, hiding, color combining
Convolve Matrix Uses neighboring pixels to modify colors
Merge Layers one image on top of another
Morphology Flattens or thins an object
Turbulence Creates artificial textures and surfaces
Offset Simple object shifting
Displacement Map Distorts a bitmap using another as input
Blend Mixes brightness and color values

Every filter in the effect pipeline has one or more inputs from which it draws the image data. The black lines to the right of the filter list demonstrate this (call-out 3). Typically, the first filter is associated with the Source Graphic , with all others deriving input from the preceding filter. However, you can go back to earlier steps or the unchanged source graphic.

You change an input source by dragging the little triangle next to the filter name either to a preceding filter or over to the right to one of the gray columns. Source Graphic represents the entire object, including its outline, to which the effect is applied.

Alternatively, you can choose the fill or stroke color, the background of the filtered object, and the transparency value of the object or its background as input. You can drag a filter to rearrange its order in the list. Add new filter primitives by selecting them from the drop-down menu underneath the filter list (call-out 4).

Unfortunately, the result of many SVG filters is not as easy to discern as the Gaussian blur . An Offset primitive, for example, shifts the pixels of the first input based on the strength of the brightness value of the second input. Combined with a luminance primitive, this filter forms a kind of spatial pattern. Scattering and swirling effects can also be applied.

The "Base Effects in Inkscape" lists all 14 of the filter primitives in Inkscape 0.48 with a short description based on the Inkscape handbook [3], which goes into greater detail.

Buy this article as PDF

Express-Checkout as PDF

Pages: 4

Price $0.99
(incl. VAT)

Buy Ubuntu User

SINGLE ISSUES
 
SUBSCRIPTIONS
 
TABLET & SMARTPHONE APPS
Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content