block.cc File Reference
Include dependency graph for block.cc:

Functions | |
| static radians_t | angle_change (point_t v1, point_t v2) |
| util; How much was v1 rotated to get to v2? | |
| static radians_t | angles_sum (vector< point_t > const &vs) |
| static void | canonicalize_winding (vector< point_t > &pts) |
| static vector< point_t > | find_vectors (vector< point_t > const &pts) |
| util; find vectors between adjacent points, pts[next] - pts[cur] | |
| static bool | is_canonical_winding (vector< point_t > const &ps) |
| Util. | |
| static void | pi_ize (radians_t &angle) |
| util; puts angle into -pi/2, pi/2 | |
| static void | positivize (radians_t &angle) |
| util; puts angle into [0, 2pi) | |
| void | swap (int &a, int &b) |
Function Documentation
util; How much was v1 rotated to get to v2?
util; finds sum of angle changes, from each vertex to the next one (in current ordering), wrapping around.
| static void canonicalize_winding | ( | vector< point_t > & | ps | ) | [static] |
util; sums angle changes to see whether it's 2pi or -2pi. 2pi is counter-clockwise winding (which OpenGL requires), -2pi is clockwise. Reverses <pts> when winding is clockwise.
util; find vectors between adjacent points, pts[next] - pts[cur]
| static bool is_canonical_winding | ( | vector< point_t > const & | ps | ) | [static] |
Util.
| static void pi_ize | ( | radians_t & | angle | ) | [static] |
util; puts angle into -pi/2, pi/2
| static void positivize | ( | radians_t & | angle | ) | [static] |
util; puts angle into [0, 2pi)
| void swap | ( | int & | a, |
| int & | b | ||
| ) |
Generated on Thu Dec 29 2011 16:43:39 for Stage by
1.7.5.1
