From cc5c3f01c6958685130a9a037abaa4dd3df86b20 Mon Sep 17 00:00:00 2001 From: John Mark Bell Date: Fri, 23 Jan 2009 19:29:03 +0000 Subject: Introduce fixed point constants. Range check azimuth angles. svn path=/trunk/libcss/; revision=6183 --- src/utils/fpconstants.h | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 src/utils/fpconstants.h (limited to 'src/utils/fpconstants.h') diff --git a/src/utils/fpconstants.h b/src/utils/fpconstants.h new file mode 100644 index 0000000..0718209 --- /dev/null +++ b/src/utils/fpconstants.h @@ -0,0 +1,20 @@ +/* + * This file is part of LibCSS. + * Licensed under the MIT License, + * http://www.opensource.org/licenses/mit-license.php + * Copyright 2008 John-Mark Bell + */ + +#ifndef css_utils_fpconstants_h_ +#define css_utils_fpconstants_h_ + +/* Useful angles */ +#define F_PI 0x00000c91 /* 3.1415 (PI) */ +#define F_2PI 0x00001922 /* 2 PI */ + +#define F_360 0x0005a000 /* 360 */ + +#define F_100 0x00019000 /* 100 */ + +#endif + -- cgit v1.2.3