Added static casts for double -> float.