FireMonkey Image Effects
Go Up to FireMonkey Applications Guide
The FireMonkey built-in ImageFX engine provides over 50 GPU-powered effects. These effects are nonvisual components that can be found in the Effects category on the Tool Palette. All the provided effects can be simply enabled or disabled by setting the Enabled flag from the Form Designer, or programmatically.
Almost all the effects have specific properties that you can customize depending on the application. For example, all transition effects have the Progress property, which is used to set the amount of progress (in percentages, %) through the transition from the first texture to the second texture. The specified properties can be found in the Object Inspector when the effect is selected in the Structure View. All numeric properties of any effect can be animated to provide a gradual evolution in time. Image effects can also be triggered.
FireMonkey effects are built using shader filters. The shaders modify pixels, either individually or in concert with others, to achieve various visual effects. These effects are not limited to bitmap image data; effects can be applied to the pixels of any 2D control in the user interface. Effects can be used at run time or at design time to change the look of the user interface of the application. The FireMonkey effects do not disable any controls or functionalities when they are applied.
For more information about applying a FireMonkey effect, see Applying FireMonkey Image Effects.
Kinds of Image Effects
The provided subclasses of TEffect fall into the categories listed in the following table. Each category is further described and illustrated later in this topic.
Effects that modify pixels individually |
Effects that consider the neighbors of a pixel |
Additive effects | Effects that modify the image as a whole |
Transition effects |
---|---|---|---|---|
Blur Distortions |
Effects that modify pixels individually
These effects typically apply changes to color. Each pixel color can be considered on its own. The table below shows some of this kind of effect:
Effect | Result | Description | Effect | Result | Description |
---|---|---|---|---|---|
None |
No effects applied. |
Grayscale transformation. | |||
Inverts the color of each pixel |
Adjusting contrast | ||||
Adjusting hue |
Fill effects |
Color filling, either preserving alpha or completely overwriting. |
Effects that consider the neighbors of a pixel
This type of effect is applied using algorithms that use the neighbors of a pixel to define the new value of the pixel. The table below shows some of this kind of effect:
Blur effects
Effect | Result | Description | Effect | Result | Description |
---|---|---|---|---|---|
None |
No effects applied. |
Gaussian blur | |||
Box blur |
Directional blur | ||||
Radial blur |
Stack Blur |
Various distortions
Effect | Result | Description | Effect | Result | Description |
---|---|---|---|---|---|
None |
No effects applied. |
Swirls effects
TSwirlEffect and |
Swirls the input image. | ||
Applies a wave patterns |
Outlines the input image | ||||
Reduces the input details |
Magnifying glass. |
Effects that modify the image as a whole
This kinds of effect applies geometric changes over the input image. The table below shows some of this kind of effect:
Effect | Result | Description | Effect | Result | Description |
---|---|---|---|---|---|
None |
No effects applied. |
Crops the input image. | |||
Rotates and scales the input image. |
3D perspective | ||||
Overlies two images. This work when the overlay has some transparency. |
Tiles the input image |
Additive effects
This kind of effect affects the images by adding new elements to the original image. The elements can be added to the edges of the image or to the entire image. The table below shows some of this kind of effect:
Effect | Opaque image | Image with transparent areas | Description |
---|---|---|---|
None |
No effects applied. | ||
Adds a glowing band | |||
Adds a glowing band in the interior of the nontransparent areas. | |||
Adds shadow to the nontransparent areas. | |||
Adds reflection to the entire image. | |||
Adds a bevel to the entire image. |
Transition effects
FireMonkey includes over twenty image transition effects, in which source pixels are progressively transformed into a target bitmap image, from simple fades to fancy banded swirls. The progress of the transformation is deterministic and can be set to an arbitrary percentage. This percentage can be animated to transition over time. To animate the progress of the transformation, see Apply an Animation Effect to a Property of an Image Effect.
The table below shows some animated transitions:
Transition | Result | Transition | Result |
---|---|---|---|
FireMonkey Image Sample Program
The ShaderFilters sample program demonstrates many of the FireMonkey image effects, except the additive effects and the basic stack blur.
See Also
Samples
- FireMonkey Image Filters sample