Skip to content
This repository has been archived by the owner on Feb 11, 2021. It is now read-only.

Commit

Permalink
Fixed argument order to the line clipping routine
Browse files Browse the repository at this point in the history
  • Loading branch information
slouken committed Dec 23, 2008
1 parent 4f8e2f5 commit 743e4d3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/video/SDL_blendline.c
Expand Up @@ -204,7 +204,7 @@ SDL_BlendLine(SDL_Surface * dst, int x1, int y1, int x2, int y2,
}

/* Perform clipping */
if (!SDL_IntersectRectAndLine(&dst->clip_rect, &x1, &x2, &y1, &y2)) {
if (!SDL_IntersectRectAndLine(&dst->clip_rect, &x1, &y1, &x2, &y2)) {
return (0);
}

Expand Down
2 changes: 1 addition & 1 deletion src/video/SDL_drawline.c
Expand Up @@ -34,7 +34,7 @@ SDL_DrawLine(SDL_Surface * dst, int x1, int y1, int x2, int y2, Uint32 color)
}

/* Perform clipping */
if (!SDL_IntersectRectAndLine(&dst->clip_rect, &x1, &x2, &y1, &y2)) {
if (!SDL_IntersectRectAndLine(&dst->clip_rect, &x1, &y1, &x2, &y2)) {
return (0);
}

Expand Down
2 changes: 1 addition & 1 deletion src/video/SDL_video.c
Expand Up @@ -2125,7 +2125,7 @@ SDL_RenderLine(int x1, int y1, int x2, int y2)
real_rect.y = 0;
real_rect.w = window->w;
real_rect.h = window->h;
if (!SDL_IntersectRectAndLine(&real_rect, &x1, &x2, &y1, &y2)) {
if (!SDL_IntersectRectAndLine(&real_rect, &x1, &y1, &x2, &y2)) {
return (0);
}
return renderer->RenderLine(renderer, x1, y1, x2, y2);
Expand Down

0 comments on commit 743e4d3

Please sign in to comment.