@ -545,7 +545,7 @@ void ImDrawList::_OnChangedVtxOffset()
int ImDrawList : : _CalcCircleAutoSegmentCount ( float radius ) const
{
// Automatic segment count
const int radius_idx = ( int ) ( radius + 0.999 f) ; // ceil to never reduce accuracy
const int radius_idx = ( int ) ( radius + 0.999 999 f) ; // ceil to never reduce accuracy
if ( radius_idx < IM_ARRAYSIZE ( _Data - > CircleSegmentCounts ) )
return _Data - > CircleSegmentCounts [ radius_idx ] ; // Use cached value
else
@ -1026,9 +1026,10 @@ void ImDrawList::AddConvexPolyFilled(const ImVec2* points, const int points_coun
}
}
// 0: East, 3: South, 6: West, 9: North, 12: East
void ImDrawList : : PathArcToFast ( const ImVec2 & center , float radius , int a_min_of_12 , int a_max_of_12 )
{
if ( radius = = 0.0f )
if ( radius < = 0.0f )
{
_Path . push_back ( center ) ;
return ;
@ -1052,7 +1053,7 @@ void ImDrawList::PathArcToFast(const ImVec2& center, float radius, int a_min_of_
void ImDrawList : : PathArcTo ( const ImVec2 & center , float radius , float a_min , float a_max , int num_segments )
{
if ( radius = = 0.0f )
if ( radius < = 0.0f )
{
_Path . push_back ( center ) ;
return ;