== Overview
This article explains how to interpolate between a base skin texture of a character and a modified sunburned version of the same. The gradient from one to another can be controlled by the end-user by moving a slider to get all the intermediated values as well.
(WARNING) We recommend visiting the [[ https://work.anticto.com/w/mutable/unreal-engine-4/user-documentation/basic-concepts/ | Basic Concepts ]] page before start creating any Customizable Object.
= Control the gradation of sunburned skin with a slider
(NOTE) The resulting Customizable Object of this example can be found in the [[https://work.anticto.com/w/mutable/unreal-engine-4/examples/#village-demo | Village Demo ]] in //Content/HowTo/TextureInterpolation// named "Texture Interpolation"
== Assets required
* One material asset or material instance of a character with one color parameter
* One skeletal mesh of the character with the previous material applied
* One texture asset of the base skin texture of the character
* One texture asset of the character’s skin modified (sunburned)
(NOTE) The assets used in this example can be found in the [[ https://work.anticto.com/w/mutable/unreal-engine-4/examples/#village-demo | Village Demo ]] in //Content/HowTo/TextureInterpolation//
== Steps
1) The first step is to create a basic [[ https://work.anticto.com/w/mutable/unreal-engine-4/user-documentation/create-a-basic-customizable-object/ | Customizable Object]] asset with the **Base Object**, the **Material**, and the **Skeletal Mesh**. Link all the connections with the same name.
{F103353}
> In this example, the Customizable Object asset is named "Texture Interpolation", the **Reference Skeletal** is "Texture Interpolation_BaseBody", the **Material** is called “Texture Interpolation_M” and the **Skeletal Mesh** is the same as the Reference Skeletal’s one. Link the “Mesh” connections between them, but leave the “Base Color” disconnected.
---
2) The objective of this example is to interpolate between two textures, the base skin and the sunburned skin one and control its gradation by moving a slider. To begin with, a [[ https://work.anticto.com/w/mutable/unreal-engine-4/user-documentation/nodes/texture-interpolate/ |Texture Interpolate]] node must be created from the “Base Color” connection of the **Material** node.
{F103355}
---
3) In the Node Properties tab, leave the Number Targets as default, because the blending should be between two textures.
{F103357}
---
4) The “Factor” connection allows choosing an interpolation parameter, that in this case should be a slider. Create a [[ https://work.anticto.com/w/mutable/unreal-engine-4/user-documentation/nodes/float-parameter/ |Float Parameter]] node by dragging and dropping from the "Factor" connection of the **Texture Interpolate** node.
{F103359}
---
5) In the Node Properties tab, change the “Default Value” to "0" to change the slider's selector position and make it be at the starting point, the base skin texture. Write a name for the parameter.
{F103361}
> In this example, the Parameter Name is “Sunburned Skin” and the “Default Value” is changed to “0”.
---
6) Now, the “Target 0” should be connected to the base skin texture, because this is the default texture from which the gradation to the sunburned skin starts. Link the “Target 0” connection of the **Texture Interpolate** node to the “Base Color” of the **Skeletal Mesh** node. The base color texture is already applied to the **Material** and the **Skeletal Mesh **assets, for this reason, it has its own slot.
{F103363}
---
7) Finally, the second target must be set up. Create a [[ https://work.anticto.com/w/mutable/unreal-engine-4/user-documentation/nodes/texture/|Texture]] from the “Target 1” connection of the **Texture Interpolate** node.
{F103365}
---
8) In the Node Properties tab, select the modified sunburned skin texture.
{F103367}
> In this case, the selected texture is “TextureInterpolation_SunburnedSkin”
---
9) Check that the Source Graph tab looks like the image below.
{F103369}
---
10) Compile. In the Preview Instance Properties tab, a slider called //Sunburned Skin// should have appeared.
{F103371}
Move the slider's selector and verify that the interpolation works properly.
{F103373}