@@ -3569,15 +3569,17 @@ void ImageDrawLineEx(Image *dst, Vector2 start, Vector2 end, int thick, Color co
3569
3569
if ((dx != 0 ) && (abs (dy /dx ) < 1 ))
3570
3570
{
3571
3571
// Line is more horizontal
3572
+
3573
+ // How many additional lines to draw
3572
3574
int wy = thick - 1 ;
3573
3575
3574
- //Draw the main line and lower half
3576
+ // Draw the main line and lower half
3575
3577
for (int i = 0 ; i <= ((wy + 1 )/2 ); i ++ )
3576
3578
{
3577
3579
ImageDrawLine (dst , x1 , y1 + i , x2 , y2 + i , color ); // Draw below the main line
3578
3580
}
3579
3581
3580
- //Draw the upper half
3582
+ // Draw the upper half
3581
3583
for (int i = 1 ; i <= (wy /2 ); i ++ )
3582
3584
{
3583
3585
ImageDrawLine (dst , x1 , y1 - i , x2 , y2 - i , color ); // Draw above the main line
@@ -3586,6 +3588,8 @@ void ImageDrawLineEx(Image *dst, Vector2 start, Vector2 end, int thick, Color co
3586
3588
else if (dy != 0 )
3587
3589
{
3588
3590
// Line is more vertical or perfectly horizontal
3591
+
3592
+ // How many additional lines to draw
3589
3593
int wx = thick - 1 ;
3590
3594
3591
3595
//Draw the main line and right half
@@ -3594,7 +3598,7 @@ void ImageDrawLineEx(Image *dst, Vector2 start, Vector2 end, int thick, Color co
3594
3598
ImageDrawLine (dst , x1 + i , y1 , x2 + i , y2 , color ); // Draw right of the main line
3595
3599
}
3596
3600
3597
- //Draw the the left half
3601
+ // Draw the left half
3598
3602
for (int i = 1 ; i <= (wx /2 ); i ++ )
3599
3603
{
3600
3604
ImageDrawLine (dst , x1 - i , y1 , x2 - i , y2 , color ); // Draw left of the main line
0 commit comments