136 vec2 normVec2d(normVec3d.
x, normVec3d.
z);
143 normVec2d.
set(1.0f, 0.0f);
147 if ((normVec2d.
x >= 0.0f) && (normVec2d.
y >= 0.0f))
152 else if ((normVec2d.
x < 0.0f) && (normVec2d.
y >= 0.0f))
157 else if ((normVec2d.
x < 0.0f) && (normVec2d.
y < 0.0f))
180 vec3 v(sinTheta * sinRho, cosTheta, sinTheta * cosRho);
A polar coordinate inline class, consisting of 2 angles theta (latitude) and rho (longitude).
Definition polar.h:28
void set(const polar &p)
set to polar object
Definition polar.h:109
scalar theta
Definition polar.h:49
polar()
the default constructor
Definition polar.h:57
vec3 get_cartesian() const
convert to normalized cartesian coords
Definition polar.h:174
void operator=(const polar &rhs)
the assignment operator
Definition polar.h:99
scalar rho
Definition polar.h:50
Different curves.
Definition angularpfeedbackloop.h:17
__forceinline constexpr scalar deg2rad(scalar d)
Definition scalar.h:468
__forceinline scalar asin(scalar x)
Definition scalar.h:209
__forceinline plane normalize(const plane &p)
Definition plane.h:255
float scalar
Definition scalar.h:45
__forceinline scalar cos(scalar x)
Definition scalar.h:191
__forceinline scalar acos(scalar x)
Definition scalar.h:218
__forceinline scalar sin(scalar x)
Definition scalar.h:182
Nebula's scalar datatype.
#define TINY
Definition scalar.h:41
A 2-component float vector class.
Definition vec2.h:21
void set(scalar x, scalar y)
set content
Definition vec2.h:198
scalar x
Definition vec2.h:86
static vec2 normalize(const vec2 &v)
return normalized version of vector
Definition vec2.h:321
scalar y
Definition vec2.h:87
scalar length() const
return length of vector
Definition vec2.h:228
A 3D vector.
Definition vec3.h:40
float x
Definition vec3.h:94
float z
Definition vec3.h:94
float y
Definition vec3.h:94