0
$\begingroup$

I have a plane with the following material on it 1

But, I wish to create a radial wipe kinda effect on the plane. Any idea how I can go about doing so?

$\endgroup$
1
  • 3
    $\begingroup$ It will be helpful to anyone answering this to know how you're generating the existing material as this will be relevant as to how to wipe the marks radially. Please edit your question will additional info to explain your current setup in more detail. $\endgroup$ Commented Mar 3, 2021 at 11:43

1 Answer 1

3
$\begingroup$

You can split the generated coordinates to get the X position:

And Y position:

Based on those you can calculate an angle:

As you can probably see, it's an angle around the bottom left corner, because that corner has coordinates X:0; Y:0. In order to fix that, you have to convert the ranges of the coordinates from 0..1 to -1..1 (- 0.5 = -0.5..0.5 *2 = -1..1) or using Object coordinate instead, since the origin point of your plane is in the center:

Half of it is black, because the result of the Arctan2 node is in range of all possible angles expressed in radians, so from roughly -3.14 rad (-180°) to roughly +3.14 rad (+180°). You could use the Math node in "To Degrees" mode to get -180..180 range, divide by 360 for -0.5..0.5 and add 0.5 for 0..1 And then scale it down (so divide again) to the actual size of the transition you want to achieve and add an offset based on the frame (or custom property), but it would be a little redundant and you can get away with much less nodes:

Multiply image alpha by it and you're done.

$\endgroup$
3
  • 1
    $\begingroup$ Haven't you just reinvented the Gradient > Radial node? $\endgroup$
    – Robin Betts
    Commented Mar 3, 2021 at 16:34
  • 1
    $\begingroup$ @RobinBetts oh, indeed, I didn't think of that. The Separate XYZ + Arctan2 could be replaced with Radial Gradient node. Similarly, MultiplyAdd could be replaced by a colorRamp, though very often I find it more intuitive to use Maths than preexisting nodes. $\endgroup$ Commented Mar 3, 2021 at 16:41
  • $\begingroup$ With you.. I get that. :) $\endgroup$
    – Robin Betts
    Commented Mar 3, 2021 at 16:43

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .