1#![feature(decl_macro)]
37#![feature(stmt_expr_attributes)]
38
39pub use vek::approx;
40pub use vek::num_traits; pub use vek;
42
43pub mod data;
44pub mod geometry;
45pub mod algebra;
46
47mod fixed;
48mod traits;
49mod types;
50
51pub use self::fixed::*;
52pub use self::traits::*;
53pub use self::types::*;
54
55pub const COMPONENT_INDEX_X : usize = 0;
57pub const COMPONENT_INDEX_Y : usize = 1;
59pub const COMPONENT_INDEX_Z : usize = 2;
61pub const COMPONENT_INDEX_W : usize = 3;
63
64
65#[doc(hidden)]
67#[macro_export]
68macro_rules! show {
69 ($e:expr) => { println!("{}: {:?}", stringify!($e), $e); }
70}
71
72pub fn report_sizes() {
74 use std::mem::size_of;
75 println!("report sizes...");
76 show!(size_of::<Vector2 <f32>>());
77 show!(size_of::<Vector3 <f32>>());
78 show!(size_of::<Vector4 <f32>>());
79 show!(size_of::<Matrix2 <f32>>());
80 show!(size_of::<Matrix3 <f32>>());
81 show!(size_of::<Rotation2 <f32>>());
82 show!(size_of::<Rotation3 <f32>>());
83 show!(size_of::<AffineMap <f32, Point3 <f32>, Point3 <f32>, Matrix3 <f32>>>());
84 show!(size_of::<AffineMap <f32, Point4 <f32>, Point4 <f32>, Matrix4 <f32>>>());
85 println!("...report sizes");
86}