About classes

Since the first release of Ultra Fractal in 1998, the formulas written for it have become larger and more complex. Even though many formulas are quite similar, they could not share any common code, but had to be written as stand-alone formulas. For example, if you wanted to add just one new feature to an existing formula written by someone else, you had to create a new formula, duplicate all the code from the original formula, and only then add some new things.

To improve this situation, formulas in Ultra Fractal 5 can re-use common code via classes. You can view a class as a "black box" that adds functionality to a formula. Via class parameters, a formula enables you to select the actual class that performs an action for the formula.

The formula declares what kind of functionality it needs and you can select any compatible class to actually implement it. This makes it possible for formula authors to write a new class to implement just the new feature that they want to add to an existing formula. The formula doesn't have to be changed at all. You just select the new class when you use the formula.

For formula authors, classes make it easier to write and manage complex formulas. For everyday users, classes make it possible to combine existing elements in new ways without needing to do any programming.

Next: Example 1 - Formula classes

See Also
Fractal formulas
Writing formulas