/*<html><body bgcolor=#B4C4B0><font color=#000000><strong><pre>*/
#ifndef	V_QOPS_H
#define V_QOPS_H

/*
 * Quake - style vector routines compatibility header
 */

#define	qboolean						vboolean
#define	matrix3d_t						matrix3_t

typedef	vec_t							vec5_t[5];
typedef	int								fixed4_t;
typedef	int								fixed8_t;
typedef	int								fixed16_t;

#define	DotProduct(v1,v2)				vec3Dot(v1,v2)
#define	VectorClear(v)					vec3Zero(v)
#define	VectorSet(v,x,y,z)				vec3Set(v,x,y,z)
#define	VectorCopy(in,out)				vec3Copy(out,in)
#define	VectorInverse(v)				vec3Negate(v,v)
#define	VectorNegate(in,out)			vec3Negate(out,in)
#define	VectorScale(in,scale,out)		vec3Scale(out,in,scale)
#define	VectorRadiansToDegrees(in,out)	vec3ToDegrees(out,in)
#define	VectorDegreesToRadians(in,out)	vec3ToRadians(out,in)
#define	VectorScaleByVector(in,scale,out) vec3ScaleByVec3(out,in,scale)
#define	Vec3SubtractAssign(value,subFrom) vec3Sub(subFrom,subFrom,value)
#define	Vec3AddAssign(value,addTo)		vec3Add(addTo,addTo,value)
#define	Vec3MultAssign(value,multBy)	vec3ScaleByVec3(multBy,multBy,value)
#define	Vec3ScaleAssign(value,scaleBy)	vec3Scale(scaleBy,scaleBy,value)
#define	FloatIsZeroEpsilon(f)			IsZero(f)
#define	FloatIsZero(f,epsilon)			(v_abs(f) < epsilon)
#define	Vec3EqualsEpsilon(v1,v2)		(IsZero(v1[0]-v2[0])&&\
										 IsZero(v1[1]-v2[1])&&\
										 IsZero(v1[2]-v2[2]))
#define	Vec3IsZero(vec)					(IsZero(vec[0])&&IsZero(vec[1])&&\
										 IsZero(vec[2]))
#define	Vec3NotZero(vec)				!Vec3IsZero(vec)

#endif	/* V_QOPS_H */
/*</pre></strong></body></html>*/
/*EOF*/
