Fixes for iOS 7.1 @ 64-bit

There were a number of instances where floats and doubles were cast into CGFloat variables. This caused incorrect values due to the 32 to 64 bit conversions and vice versa that started happening since iOS 7.1. These fixes are not pretty, but they do work. :cry: