# HG changeset patch # User Sam Lantinga # Date 1262763435 0 # Node ID ce7d4942d18b1962762cc6b0d6ee9851612589c0 # Parent 57823d017f026a97eb8b42268a8aba1a65c18892 I can't compile this, but it should be updated for the new rendering API now. diff -r 57823d017f02 -r ce7d4942d18b src/video/win32/SDL_gapirender.c --- a/src/video/win32/SDL_gapirender.c Wed Jan 06 07:34:20 2010 +0000 +++ b/src/video/win32/SDL_gapirender.c Wed Jan 06 07:37:15 2010 +0000 @@ -38,10 +38,14 @@ /* GAPI renderer implementation */ static SDL_Renderer *GAPI_CreateRenderer(SDL_Window * window, Uint32 flags); -static int GAPI_RenderPoint(SDL_Renderer * renderer, int x, int y); -static int GAPI_RenderLine(SDL_Renderer * renderer, int x1, int y1, - int x2, int y2); -static int GAPI_RenderFill(SDL_Renderer * renderer, const SDL_Rect * rect); +static int GAPI_RenderDrawPoints(SDL_Renderer * renderer, + const SDL_Point * points, int count); +static int GAPI_RenderDrawLines(SDL_Renderer * renderer, + const SDL_Point * points, int count); +static int GAPI_RenderDrawRects(SDL_Renderer * renderer, + const SDL_Rect ** rects, int count); +static int GAPI_RenderFillRects(SDL_Renderer * renderer, + const SDL_Rect ** rects, int count); static int GAPI_RenderCopy(SDL_Renderer * renderer, SDL_Texture * texture, const SDL_Rect * srcrect, @@ -459,9 +463,10 @@ return NULL; } - renderer->RenderPoint = GAPI_RenderPoint; - renderer->RenderLine = GAPI_RenderLine; - renderer->RenderFill = GAPI_RenderFill; + renderer->RenderDrawPoints = GAPI_RenderDrawPoints; + renderer->RenderDrawLines = GAPI_RenderDrawLines; + renderer->RenderDrawRects = GAPI_RenderDrawRects; + renderer->RenderFillRects = GAPI_RenderFillRects; renderer->RenderCopy = GAPI_RenderCopy; renderer->RenderPresent = GAPI_RenderPresent; renderer->DestroyRenderer = GAPI_DestroyRenderer; @@ -497,23 +502,38 @@ } static int -GAPI_RenderPoint(SDL_Renderer * renderer, int x, int y) +GAPI_RenderDrawPoints(SDL_Renderer * renderer, + const SDL_Point * points, int count) { - //TODO implement + // TODO implement + SDL_Unsupported(); return -1; } static int -GAPI_RenderLine(SDL_Renderer * renderer, int x1, int y1, int x2, int y2) +GAPI_RenderDrawLines(SDL_Renderer * renderer, + const SDL_Point * points, int count) { - //TODO implement - return -11; + // TODO implement + SDL_Unsupported(); + return -1; } static int -GAPI_RenderFill(SDL_Renderer * renderer, const SDL_Rect * rect) +GAPI_RenderDrawRects(SDL_Renderer * renderer, + const SDL_Rect ** rects, int count) { - //TODO implement + // TODO implement + SDL_Unsupported(); + return -1; +} + +static int +GAPI_RenderFillRects(SDL_Renderer * renderer, + const SDL_Rect ** rects, int count) +{ + // TODO implement + SDL_Unsupported(); return -1; }