Render to target UV painting, but can it fade?

I’m trying to experiment to see if it’s even possible for a game idea (crime solving sort of thing), trying to replicate a substance called Luminol. This is a chemical that basically reacts with oxygen in blood stains, and glows. So far so good, I’ve got that and that’s in this video:

But the chemical fades over time, that’s where the problem comes in. I’m not sure exactly how to do that, due to the way Unreal seems to handle Render to Target real time drawing. Below are pictures of my materials/blueprints:

So does anyone have any idea how I could achieve a per stroke fade effect, almost similar to particle lifespans?

Use another brush that’s just a grey color to cover the whole render target and apply that every tick. I do not remember how I subtracted (negative value in an additive material?) from the tender target, but I had done this for heat mapping in a previous project. The grey tone needs to be incredible subtle to work. The closer to black, the slower the fade. Likewise, the closer to white, the faster the fade.

For anyone finding this thread via google. The solution is to create a material, set it’s blend mode to modulate and emmissive color to a very bright gray. Then use that material to draw it onto your render target on tick using your scene captures “Draw Material to Render Target” function.



1 Like