3
$\begingroup$

I have a procedural texture with a circle made by formula $x^2 + y^2 \lt r^2$. It looks like a circle on a plane. But if I try to use this formula in the World environment - the circle is distorted.

How to convert $xy$ coordinates in the formula to the equirectangular coordinates to have the clear circle in the environment?

It's not about especially for the circle, I need to have the formula to translate any procedurally generated plane texture to equirectangular.

enter image description here

$\endgroup$
1
  • $\begingroup$ It's very late, but still-- if you recreate equirectangular mapping in nodes, you're going to have the exact same distortion that you have with using equirectangular mapping. You're approaching this the wrong way. If you want a circle, do it by dot product >= constant; if you want to make an equirectangular map without distortion, do it by making an equirectangular render. $\endgroup$
    – Nathan
    Commented Apr 9, 2021 at 16:59

1 Answer 1

1
$\begingroup$

It seems to me, that the number, that used in Power node is not exactly equals 2. It can be like 2.0001, but in widget it rounds 2. Why is important? Coordinates are in range -1 ... 1 so part of coordinates are negative. And raising a negative number to a fractional degree is impossible (because of math), so it brakes the resulted circle.

Equals 2: enter image description here

Does not equal 2: enter image description here

$\endgroup$
3
  • 2
    $\begingroup$ Raising a negative number to a fractional degree is an every day thing in math actually. For us all especially no matter the fact that it might break things here. Quaternion rotations use the concept of so called 'imaginary' numbers. It is no different concept than negative numbers for example - we do not count in negative numbers in real world - it's only a math concept and so is a root of -1 apparently. I will never forgive my math teacher for lying about that :D ... $\endgroup$ Commented Nov 6, 2018 at 22:42
  • 1
    $\begingroup$ Quaternions are one step beyond your common-or-garden imaginary numbers :D $\endgroup$
    – Robin Betts
    Commented Nov 6, 2018 at 23:12
  • $\begingroup$ It doesn't work. Anyway, this changes the source circle formula. But I need the universal way to translate with no source changes. What about square or any other procedural generated texture? No chance to change them. Is there any formula to translate one coordinate system (xy) to another (equirectangular)? The procedural circle must be made with an inverse of this formula and after applying to the world it becomes proper circle. $\endgroup$
    – Korchiy
    Commented Nov 7, 2018 at 5:28

You must log in to answer this question.

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