I don’t think ‘isometric angles’ is even a term, but I’m referring to how an angle should appear like in isometric view.
The image below describes the situation.
Given an angle (75deg and 45deg depicted in red arrows above), what is computed angle if the circle was compressed by half (ie an isometric view). The small ellipse depict a circle in isometric view.
The yellow arrows depict the scaling effect of the point on the big white circle and is projected to touch the isometric circle.
The green arrows represent the vectors whose angles I am computing.
I must apologise to any potential researcher that this solution is entirely homemade and there might be more elegant solutions out there.
- With a given angle, determine the normalised length of the Adjacent side
A. This is done by
- The length of the
Aenables the measurement of the Opposite side
Ois computed by multiply
Awith the tan() ratio of the angle:
O = tan(angle)*A
- Now that O has been found out (the yellow arrow line depicted above), scale the length down as per the isometric projection. For simplicity, I’m scaling it by half (eg for 256×125 tile):
- Then recompute the ratio of the known A and new O2:
- The new ratio can be used to determine angle using atan():
- If angle reaches 90, then A has no length, and this corresponds with the nominal orthographic angle.
- If angle reaches 180, then O has no length, and so the same thing.
- If angle > 90 and < 180 the result of
A=cos(angle)will be negative. The same with
- If angle > 180 and < 270 then A=cos(angle) will be negative still, but tan(angle) will be positive.
- If angle > 270 and < 360 then A=cos(angle) will be positive, and tan(angle) will be negative.
- When result angle is reached, modify the value based on the quadrant of the original angle:
- If cos(angle) is negative, and tan(angle) is negative, add 180 degrees. (Quadrant 2)
- If cos(angle) is negative, and tan(angle) is positive, add 180 degrees. (Quadrant 3)
- If cos(angle) is positive, and tan(angle) is negative, add 360 degrees. (Quadrant 4)
- If cos(angle) is positive, and tan(angle) is positive, then keep result. (Quadrant 1)
The images above show 45 degrees as pointing NE. In C2, however, it’s pointing SE. But this orientation allowed me to understand what was going on.
To reverse the operation, to get the orthogonal angle from an isometric angle, reverse tile’s width/height in O2: