Make glowing colors flow from one end of face to other end?

Using moving gradients, how do I get glowing lights to travel on the faces and edges of the mesh from one end to the other?

Like in this video, from 0:00-0:02.


2)

3)

As per the screenshots, how do I get glowing effect to travel across the selected faces and edges of a mesh from one point to another? Thanks.

How I tried:

While a good blender answer covered this topic regarding moving gradients, how to do this in Unreal Engine 5? Especially changing gradient color and direction of gradient flow.

Hi Francis,

I’ve been able to achieve a similar result by panning a gradient inside of a material:

Note that the texture in ‘ColorMap’ does not come with the editor (But any gradient would work) also the direction of the gradient will determine what direction you’re panning the texture (Speed U or Speed V)

You’d then multiply or add the result with everything else.

Cheers

1 Like

To expand @Astrotronic setup, here is one with the Linear Gradient included:

And depending on which output from the Gradient you use, you can switch between left-right movement, or up-down movement - wich then can speed up or changed in the direction with the Speed value, that you feed into the panner. Positive numbers go one way, negative numbers go the other way.

Edit: Just for fun, with switching out some nodes, you also can create a cool scanline effect :slight_smile:
Be warned about the insane intensity, that those Color Dodge nodes create, i had to throw in that power node to heavily tone the intensity down, maybe a clamp node should be added too, to limit the max glow intensity:

4 Likes

Thanks for the answer. Now, where do I find Speed U, Speed V, and Param2D as per your screenshot?

My attempt to copy your answer:

How do I get your Color Map Param2D? Thanks

On second thought, I did manage to replicate your answer successfully:

Now, how do I follow your coordinates, especially for gradient? Thanks

In your image the texture is missing. (Select the node to change the texture) my example I used a gradient texture from the internet, but Hats off to @Suthriel, as you can see from his example, you can use the ‘LinearGradient’ node to generate a gradient.

Also, be sure to put a non-zero value in the Speed Params to see it moving!

1 Like

Thanks for the answer. Now, I tried to copy your first screenshot, and the gradient does technically move across the texture, yes, but how do I turn that gradient red color? Also, can I use a blank texture for a gradient in the future?

If you multiply a white texture with a white LinearGradient, the result will stay white. In order to color something red, you need to multiply it with either a red texture or a red color parameter. The desaturated LinearGradient is greyscale/white - so you need something red :slight_smile:

So either use a texture in the correct color (which then gets increased intensity where the LinearGradient travels), or just mutliply it with a red color parameter.
And yeah, you can replace the LinearGradient with a texture, but then take a look at Astrotronics Panner setup, because i just have noticed thanks to his post, that the Panner speed is controlled by a Vector2, instead of just one single parameter. You may not notice it with simple gradient textures, but it currently runs diagonal, because a single parameter gets interpreted equally for U and V direction (it gets moved to the side and down at the same time), and that becomes obviouls, if you mix in a more complex texture than a simple gradient.

Modified it to use a white texture, and just added a color parameter (and renamed it Emissive Color), which i set to a red color. You can see the start of the LinearGradient turning the white texture red in the preview window in the left corner.

The sine node may show a red gradient in the preview window, but the result actually is greyscale thanks to the desaturation node. You can test that by disconnecting the base color input, and just use the emissive color for a test run, you will see a grey/white gradient wandering.

2 Likes

Thanks for the answer. Really helpful. It worked. Now, why did we need the desaturated LinearGradient? After the red gradient moving, can we put another shade of red gradient immediate before and after? Thanks

Honestly, that desaturation should not be necessary, but during building the material, i sometimes got strange results, and the Gradient got turned into several unwanted colors instead of staying grey. So i inserted it to make sure, that whatever gets feed into the Sine and comes out of it is def greyscale and not of any other unpredictable color.

For the rest… just try it out and see what happens :slight_smile:

1 Like

Thanks for the answer. I reassure you, I’m not demanding to be spoonfed, if anything, I’m a newbie at unreal engine 5, and what caught me off guard is that we’re unable to transfer gradient or other color effects from Blender to UE5.

It’s a nuisance, having to redo this all over again. Worse is that UE5 color system is totally different from Blender, meaning we gotta put in double work. :frowning_face:

Aaaah, stupid me, now i know, why i got random colors, i connected the Panner and LinearGradient in the wrong order ^.^ The correct order is, TexCoords go into Panner, the Panner outputs the new Coordinates, those then get into the LinearGradient, or your Texture of choice.

My random colors probably came from the fact, that UE can read texture coordinate inputs as colors aswell, so X coords became red, and Y coords became green. Now i wonder, why it still worked in the previous order o.o

Whatever, this should be more correct than the previous, then you also should not have any trouble replacing the LinearGradient with a texture, or with integrating another Gradient or Texture into the chain.
Just note, that this Sine node is there specifically for the LinearGradient, a texture will not require it (but after linking the into it for a testrun, it created a nice looking outline effect for this texture ^.^ ).

And since you are a Blender Guru, UE starts integrating Strata Materials with UE 5.1, which should be way closer to what you use in Blender:

https://portal.productboard.com/epicgames/1-unreal-engine-public-roadmap/c/856-strata-materials-experimental

2 Likes