Fix double to float conversion warnings