Now imagine you need to transform the source value before transferring it to the binding target. You can achieve this using a converter. The conversion can be as simple as adding 10 to the input value to something as complex as use of a custom script with conditions.
The majority of converters are available in all Composer Editions, including the Free Edition. Current converters work with a single input. Future converters will work with multiple inputs to generate a single output, adding even more flexibility.
The following converters ship with Intuiface. To create your own converter, see this section below.
- Math & Logic: add, subtract, multiply, divide numeric values or invert booleans (true/false)
- Linear Converter: convert a numeric value located within an input range into a second value located within an output range
- Date Format: format a date according to your need and country specifications
- Number Format: convert numeric values, specify the number of decimals, add local currency symbols, etc.
- Text Manipulation: modify text
- Custom Script: [for Composer Enterprise users only] Use scripting to create complex transformation formulas, like an if ... then ... else ... statement.
- Color: convert a numeric value located within an input range into a color located within an output range
Converters can be applied to any use of binding. This means a property value can be converted before it is transferred via binding to:
- a second Property of the same asset or a different one. This type of binding is defined here.
- a Trigger Parameter. This type of binding is defined here.
- an Action Parameter. This type of binding is defined here
This example illustrates how to use a converter with property-to-property binding. We will place Hello in front of the text John Smith.
- Create two Text assets. Leave one blank and type John Smith into the other.
- Open the Properties panel for the blank Text asset and then display the Binding panel.
- On the right of the Binding panel, select the Text asset containing the John Smith text - the Source Item - this will be the source of the value to be bound. Click on the Text value of the blank text and on the Text value of the Source Text John Smith. This will bind the two text values
- Hover over the binding line with your mouse and click the Converter icon
- Select the Text Manipulation converter category from the list
- Use the Concatenate converter to add the word "Hello" in front of the text John Smith.
Composer Enterprise users can create their own conversion rules using one of two methods:
- Use the built-in Custom Script converter
- Parallax effect: See how to create a Parallax effect using the Divide converter in this article.