Geometry::deg2rad() made a template. Some methods of Layer made inline. Added a helper template remove_nulls().