**Name:** gaussian_blur

**Type:** 2D blur

**Name:** pre_blur

**Type:** 2D blur pre

## Description

Carl Frederich Gauss was a preeminent early nineteenth century German mathematician and scientist. Among the many things named for him is the Gaussian distribution, also known as the normal distribution or the bell curve, which is very important in statistics. It also forms the basis of the gaussian_blur variation in JWildfire.

To understand how gaussian_blur works, let’s first consider the blur and circleblur variations. All three variations pick a random point inside a circle by choosing a random angle and a random distance from the center. They produce different results by using different methods of choosing the random distance, which can be analyzed using probability density functions.

The blur variation chooses a random number between 0 and 1 with all values equally likely; its probability density function is shown in the top left curve below. This is called a uniform distribution. The top right curve illustrates the density of the resulting disk based on the distance from its center. It has a higher density near the center than the edges because as the distance from the center decreases, the number of points gets smaller so any particular point is more likely to get chosen. In contrast, the circleblur variation uses a parabolic probability density function as shown in the middle left curve, resulting in a disk with even density across its radius.

The gaussian_blur chooses a random number between 0 and 2 using a Gaussian distribution as shown in the bottom left curve. The result doesn’t get cut off at 1 like with blur and circleblur, but continues outward getting less and less dense. This gives gaussian_blur a much softer edge than other blurs.

Gaussian_blur is a blur variation, and can be used in the same way as other blur variations; see blur. It’s soft edges make it useful where the hard edges of other blur variations would be distracting. For example, these flames are a variant of the plastic style using blob instead of linear to produce jagged edges. The first one uses blur, and its hard edge is apparent and distracting. The second one uses gaussian_blur instead to avoid this problem; the difference is subtle, but it is a more pleasing flame.

Gaussian_blur is also useful for softening sharp edges by adding a small amount to a transform with other variations, and can even be used with other blur variations to soften their shapes.

The pre_blur variation also uses the Gaussian distribution. It differs from gaussian_blur in two important ways:

- It does not ignore the input points like other blur variations. It chooses a random point like the others, but instead of replacing the input point, it adds the random point to the input point. If the amount is small, this provides a gentle blur to the input point. If the amount is large, it will overwhelm the input point.
- The “pre_” means it is applied before normal variations, so they act on the blurred points instead of the original ones. It can’t be used by itself; a normal (not pre_ or post_) variation is required on all transforms.

To see some of the ways pre_blur can be used, consider this typical splits-elliptic flame, made with four transforms: the first two use elliptic and splits to form the main structure, and the last two use cylinder to outline the structure (a common use of cylinder).

Notice how the outline from the cylinder variations has some artifacts. They are a bit distracting. We can use pre_blur to smooth them out. A small value (like 0.5) will let them show through a bit, which is sometimes desirable. But here we completely obliterate them by using a large value, specifically 10.

Much nicer! Pre_blur can also be used to create special effects. Here we add a very tiny amount (0.0075) of pre_blur to the transform with splits. The blur adds up as the flame is iterated, making areas generated by multiple iterations more blurry than areas generated by fewer iterations. This helps give emphasis to the central structure of the flame. Whether the result is “better” than before is a matter of opinion (or maybe artistic intent), but this demonstrates how pre_blur can be used to control the composition of a flame.

## Parameters

variation amount | The radius of the generated circle. |

## Resources

Blur at Fractal Formulas

Flame pack (flames used above)